Skip to content

Instantly share code, notes, and snippets.

@alexferreira
Created May 19, 2013 20:08
Show Gist options
  • Save alexferreira/5608812 to your computer and use it in GitHub Desktop.
Save alexferreira/5608812 to your computer and use it in GitHub Desktop.
Grunt for minify javascript files
module.exports = function(grunt) {
grunt.initConfig({
uglify: {
options: {
banner: '/*! application.js <%= grunt.template.today("yyyy-mm-dd hh:MM") %> */\n',
},
build: {
src: 'public/assets/application.min.js',
dest: 'public/assets/application.min.js'
}
}
});
// Load the plugin that provides the "uglify" task.
grunt.loadNpmTasks('grunt-contrib-uglify');
// Default task(s).
grunt.registerTask('default', ['uglify']);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment