adds gulpfile & a few dependencies

gulp-mocha
gulp-jshint
bunyan
jshint-stylish
This commit is contained in:
Todd Treece 2015-07-27 16:21:59 -04:00
parent c45d3eac1e
commit d1c379fe82
2 changed files with 34 additions and 1 deletions

29
gulpfile.js Normal file
View file

@ -0,0 +1,29 @@
var gulp = require('gulp'),
jshint = require('gulp-jshint'),
mocha = require('gulp-mocha');
gulp.task('lint', function() {
return gulp.src([
'lib/*.js',
'test/*.js'
]).pipe(jshint())
.pipe(jshint.reporter('jshint-stylish'));
});
gulp.task('test', function() {
return gulp.src('test/*.js', {read: false})
.pipe(mocha())
.once('error', function(err) {
console.error(err);
process.exit(1);
})
.once('end', function() {
process.exit();
});
});
gulp.task('default', ['lint', 'test']);

View file

@ -26,9 +26,13 @@
},
"homepage": "https://github.com/adafruit/nprone_raspi#readme",
"devDependencies": {
"gulp": "^3.9.0"
"gulp": "^3.9.0",
"gulp-jshint": "^1.11.2",
"gulp-mocha": "^2.1.3",
"jshint-stylish": "^2.0.1"
},
"dependencies": {
"bunyan": "^1.4.0",
"dotenv": "^1.2.0",
"oauth": "^0.9.13"
}