Skip to content

Instantly share code, notes, and snippets.

@acairns
Created October 8, 2013 14:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save acairns/6885801 to your computer and use it in GitHub Desktop.
Save acairns/6885801 to your computer and use it in GitHub Desktop.
Simple LESS & CSS min setup with Grunt.js
module.exports = function(grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
less: {
development: {
files: {
"dist/style.min.css": "src/style.less"
}
}
},
cssmin: {
development: {
options: {
keepSpecialComments: 0
},
expand: true,
src: 'dist/style.min.css',
ext: '.min.css'
}
}
});
grunt.loadNpmTasks('grunt-contrib-less');
grunt.loadNpmTasks('grunt-contrib-cssmin');
grunt.registerTask('default', ['less','cssmin']);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment