Use gulp eslint (#354)
This commit is contained in:
Родитель
07f5c5b687
Коммит
5ddb065937
|
@ -14,6 +14,15 @@ import merge from 'merge-stream';
|
|||
|
||||
const $ = gulpLoadPlugins();
|
||||
|
||||
gulp.task('lint', () => {
|
||||
return gulp.src([
|
||||
'static/**/*.js'
|
||||
])
|
||||
.pipe($.eslint())
|
||||
.pipe($.eslint.format())
|
||||
.pipe($.eslint.failAfterError());
|
||||
});
|
||||
|
||||
// Compile and automatically prefix stylesheets
|
||||
gulp.task('styles', () => {
|
||||
const AUTOPREFIXER_BROWSERS = [
|
||||
|
@ -81,6 +90,7 @@ gulp.task('clean', () => {
|
|||
gulp.task('default', ['clean'], cb =>
|
||||
runSequence(
|
||||
'styles',
|
||||
'lint',
|
||||
'vulcanize',
|
||||
'scripts',
|
||||
cb
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
"scripts": {
|
||||
"postinstall": "npm run deps; npm run build",
|
||||
"deps": "rm -rf static/bower_components; bower install",
|
||||
"lint": "eslint .",
|
||||
"lint": "gulp lint",
|
||||
"build": "gulp",
|
||||
"deploy": "./scripts/deploy_site.sh"
|
||||
},
|
||||
|
@ -24,13 +24,13 @@
|
|||
"babel-core": "^6.10.4",
|
||||
"babel-preset-es2015": "^6.9.0",
|
||||
"del": "^2.2.1",
|
||||
"eslint": "^3.1.1",
|
||||
"eslint-config-google": "^0.6.0",
|
||||
"grunt": "^0.4.5",
|
||||
"grunt-appengine": "^0.1.5",
|
||||
"gulp": "^3.9.1",
|
||||
"gulp-autoprefixer": "^3.1.0",
|
||||
"gulp-crisper": "^1.1.0",
|
||||
"gulp-eslint": "^3.0.1",
|
||||
"gulp-if": "^2.0.1",
|
||||
"gulp-load-plugins": "^1.2.4",
|
||||
"gulp-rename": "^1.2.2",
|
||||
|
|
Загрузка…
Ссылка в новой задаче