Skip to content

Commit

Permalink
remove gulp-exclude-gitignore and fix eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
jchip committed Sep 22, 2016
1 parent d05dc87 commit 127c521
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 11 deletions.
12 changes: 12 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"parserOptions": {
"ecmaVersion": 6,
"sourceType": "module",
"ecmaFeatures": {
"jsx": true
}
},
"rules": {
"semi": 2
}
}
6 changes: 2 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
language: node_js
node_js:
- v6
- v5
- v4
- '0.12'
- '0.10'
- v6
notifications:
email:
- [email protected]
- [email protected]
before_install: if [[ `npm -v` != 3* ]]; then npm i -g npm@3; npm --version; fi
7 changes: 2 additions & 5 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,18 @@
var path = require('path');
var gulp = require('gulp');
var eslint = require('gulp-eslint');
var excludeGitignore = require('gulp-exclude-gitignore');
var mocha = require('gulp-mocha');
var istanbul = require('gulp-istanbul');
var nsp = require('gulp-nsp');
var plumber = require('gulp-plumber');
var gulpIgnore = require('gulp-ignore');

function excludeTemplates() {
return gulpIgnore.exclude('**/templates/**');
return gulpIgnore.exclude(['**/templates/**', '**/node_modules/**']);
}

gulp.task('static', function () {
return gulp.src('**/*.js')
.pipe(excludeGitignore())
return gulp.src(['*.js', 'test/**/*.js', 'generators/**/*.js'])
.pipe(excludeTemplates())
.pipe(eslint())
.pipe(eslint.format())
Expand All @@ -28,7 +26,6 @@ gulp.task('nsp', function (cb) {

gulp.task('pre-test', function () {
return gulp.src('generators/**/*.js')
.pipe(excludeGitignore())
.pipe(excludeTemplates())
.pipe(istanbul({
includeUntested: true
Expand Down
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
"eslint": "^3.1.1",
"gulp": "^3.9.0",
"gulp-eslint": "^2.0.0",
"gulp-exclude-gitignore": "^1.0.0",
"gulp-ignore": "^2.0.1",
"gulp-istanbul": "^1.0.0",
"gulp-line-ending-corrector": "^1.0.1",
Expand All @@ -55,7 +54,7 @@
},
"scripts": {
"prepublish": "gulp prepublish",
"test": "gulp test"
"test": "gulp"
},
"license": "Apache-2.0"
}

0 comments on commit 127c521

Please sign in to comment.