forked from Rowland/EG
38 lines
737 B
JavaScript
38 lines
737 B
JavaScript
module.exports = function (grunt) {
|
|
grunt.initConfig({
|
|
pkgFile: 'package.json',
|
|
simplemocha: {
|
|
options: {
|
|
ui: 'bdd',
|
|
reporter: 'dot'
|
|
},
|
|
unit: {
|
|
src: [
|
|
'test/*.spec.js'
|
|
]
|
|
}
|
|
},
|
|
eslint: {
|
|
target: [
|
|
'index.js',
|
|
'gruntfile.js',
|
|
'karma.conf.js',
|
|
'test/*.js'
|
|
]
|
|
}
|
|
})
|
|
|
|
require('load-grunt-tasks')(grunt)
|
|
|
|
grunt.registerTask('test', ['simplemocha'])
|
|
grunt.registerTask('default', ['eslint', 'test'])
|
|
|
|
grunt.registerTask('release', 'Bump the version and publish to NPM.', function (type) {
|
|
grunt.task.run([
|
|
'npm-contributors',
|
|
'bump:' + (type || 'patch'),
|
|
'npm-publish'
|
|
])
|
|
})
|
|
}
|