I am trying to set two targets (dev and build) within a cssmin task in gruntfile.js. This answer cleared some of my confusion from reading the doc on npm, but I can't get both minify and combine to work. To simplify I'll focus just on the dev task, since build would be a simple variation.
I tried this:
cssmin: {
dev: {
options: {
report: "min"
},
src: "<%= buildpath %>/css/customStep1.css",
dest: "<%= buildpath %>/css/customStep2.css",
combine: {
files: {
"<%= distpath %>/css/main.css": ["<%= buildpath %>/css/customStep2.css", "<%= buildpath %>/css/otherfile.css"]
}
}
}
}
And this:
cssmin: {
dev: {
options: {
report: "min"
},
src: "<%= buildpath %>/css/customStep1.css",
dest: "<%= buildpath %>/css/customStep2.css",
files: {
"<%= distpath %>/css/main.css": ["<%= buildpath %>/css/customStep2.css", "<%= buildpath %>/css/otherfile.css"]
}
}
}
Both do create/minify customStep2.css, but neither then does the combine part (i.e. main.css does not get created). Thanks for any help.