chore(Gruntfile): add auto-build task

This commit is contained in:
jdotzki 2014-03-12 10:59:06 +01:00 committed by Nico Rehwaldt
parent 5d465cd066
commit dadf0ae1a5
2 changed files with 22 additions and 1 deletions

View File

@ -113,13 +113,33 @@ module.exports = function(grunt) {
concurrent: {
'sources': [ 'browserify:src', 'jshint' ],
'build': [ 'jshint', 'build', 'jsdoc' ]
}
},
connect: {
options: {
port: 9003,
livereload: 35726,
hostname: 'localhost'
},
livereload: {
options: {
open: true,
base: [
'<%= config.dist %>'
]
}
}
},
});
// tasks
grunt.registerTask('test', [ 'jasmine_node', 'karma:single' ]);
grunt.registerTask('build', [ 'browserify', 'copy:samples' ]);
grunt.registerTask('auto-build', [
'concurrent:build',
'connect:livereload',
'watch'
]);
grunt.registerTask('auto-test', [ 'jasmine_node', 'watch:test' ]);

View File

@ -52,6 +52,7 @@
"grunt-contrib-copy": "~0.5.0",
"moddle": "~0.0.1",
"moddle-xml": "~0.0.1",
"grunt-concurrent": "~0.4.0",
"lodash": "~2.4.0"
},
"dependencies": {