From 847b3f3697d735b5028d820a06168020d6f766af Mon Sep 17 00:00:00 2001 From: Brent Houghton Date: Mon, 9 Jun 2014 13:43:41 -0700 Subject: [PATCH] Update project config files to work with Grunt 0.4. --- grunt.js => Gruntfile.js | 27 ++++++++++++++++----------- package.json | 5 ++++- 2 files changed, 20 insertions(+), 12 deletions(-) rename grunt.js => Gruntfile.js (60%) diff --git a/grunt.js b/Gruntfile.js similarity index 60% rename from grunt.js rename to Gruntfile.js index 008da40..ccdf7bd 100644 --- a/grunt.js +++ b/Gruntfile.js @@ -1,12 +1,14 @@ +'use strict'; + module.exports = function(grunt) { + // Load grunt tasks automatically + require('load-grunt-tasks')(grunt); + // Project configuration. grunt.initConfig({ - test: { - files: ['test/**/*.js'] - }, - lint: { - files: ['grunt.js', 'tasks/**/*.js', 'test/**/*.js'] + nodeunit: { + all: ['test/**/_test.js'] }, watch: { files: '', @@ -25,16 +27,19 @@ module.exports = function(grunt) { boss: true, eqnull: true, node: true, - es5: true }, - globals: {} + all: [ + 'Gruntfile.js', + 'tasks/{,*/}*.js', + 'test/{,*/}*.js', + ] } }); - // Load local tasks. - grunt.loadTasks('tasks'); - // Default task. - grunt.registerTask('default', 'lint test'); + grunt.registerTask('default', [ + 'jshint', + 'nodeunit:all' + ]); }; diff --git a/package.json b/package.json index a677a37..ce0ae41 100644 --- a/package.json +++ b/package.json @@ -33,7 +33,10 @@ "grunt": "~0.3.9" }, "devDependencies": { - "grunt": "~0.3.9" + "grunt": "~0.4.1", + "grunt-contrib-jshint": "^0.10.0", + "grunt-contrib-nodeunit": "^0.4.0", + "load-grunt-tasks": "^0.4.0" }, "keywords": [ "gruntplugin",