Skip to content

Commit

Permalink
Implemented grunt watch.
Browse files Browse the repository at this point in the history
  • Loading branch information
goloroden committed Feb 20, 2013
1 parent b4d6a12 commit 44edfe0
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
11 changes: 10 additions & 1 deletion Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
module.exports = function (grunt) {
grunt.initConfig({
jshint: {
files: ['Gruntfile.js', 'lib/**/*.js', 'test/**/*.js'],
files: [ '**/*.js', '!node_modules/**/*.js' ],
options: {
jshintrc: 'jshint.json'
}
Expand All @@ -18,10 +18,19 @@ module.exports = function (grunt) {
reporter: 'spec',
ui: 'tdd'
}
},

watch: {
options: {
files: [ '**/*.js', '!node_modules/**/*.js' ],
tasks: [ 'default' ],
interrupt: true
}
}
});

grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-mocha-test');

grunt.registerTask('default', [ 'jshint', 'mochaTest' ]);
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"devDependencies": {
"grunt": "0.4.0",
"grunt-contrib-jshint": "0.1.1",
"grunt-contrib-watch": "0.2.0",
"grunt-mocha-test": "0.2.0",
"node-assertthat": "0.0.14"
},
Expand All @@ -21,4 +22,4 @@
"type": "git",
"url": "git://github.com/thenativeweb/timer.git"
}
}
}

0 comments on commit 44edfe0

Please sign in to comment.