Created
February 21, 2012 00:07
-
-
Save boazsender/1872458 to your computer and use it in GitHub Desktop.
Example gruntfile.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*global config:true, task:true*/ | |
config.init({ | |
pkg: '<json:package.json>', | |
meta: { | |
banner: '/*! <%= pkg.title || pkg.name %> - v<%= pkg.version %> - ' + | |
'<%= template.today("m/d/yyyy") %>\n' + | |
'<%= pkg.homepage ? "* " + pkg.homepage + "\n" : "" %>' + | |
'* Copyright (c) <%= template.today("yyyy") %> <%= pkg.author.name %>;' + | |
' Licensed <%= _.pluck(pkg.licenses, "type").join(", ") %> */' | |
}, | |
concat: { | |
'dist/grunt-jquery-example.js': ['<banner>', '<file_strip_banner:src/grunt-jquery-example.js>'] | |
}, | |
min: { | |
'dist/grunt-jquery-example.min.js': ['<banner>', 'dist/grunt-jquery-example.js'] | |
}, | |
qunit: { | |
files: ['test/**/*.html'] | |
}, | |
lint: { | |
files: ['grunt.js', 'src/**/*.js', 'test/**/*.js'] | |
}, | |
watch: { | |
files: '<config:lint.files>', | |
tasks: 'lint qunit' | |
}, | |
jshint: { | |
options: { | |
curly: true, | |
eqeqeq: true, | |
immed: true, | |
latedef: true, | |
newcap: true, | |
noarg: true, | |
sub: true, | |
undef: true, | |
eqnull: true, | |
browser: true | |
}, | |
globals: { | |
jQuery: true | |
} | |
}, | |
uglify: {} | |
}); | |
// Default task. | |
task.registerTask('default', 'lint qunit concat min'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment