aboutsummaryrefslogtreecommitdiffstats
path: root/gulpfile.js
diff options
context:
space:
mode:
authorkumavis <aaron@kumavis.me>2018-04-03 05:47:47 +0800
committerkumavis <aaron@kumavis.me>2018-04-03 05:47:47 +0800
commit2b6557a02473a0603752056544cd98d86143b342 (patch)
treec9878d0fb1a1d4c5fa8342c6e213170bd7be8da0 /gulpfile.js
parentfd30fabfbd7707adf2e4bc3606362c1687aeed9a (diff)
downloadtangerine-wallet-browser-2b6557a02473a0603752056544cd98d86143b342.tar.gz
tangerine-wallet-browser-2b6557a02473a0603752056544cd98d86143b342.tar.zst
tangerine-wallet-browser-2b6557a02473a0603752056544cd98d86143b342.zip
lint - lint json files in app/
Diffstat (limited to 'gulpfile.js')
-rw-r--r--gulpfile.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/gulpfile.js b/gulpfile.js
index 1eb0a974b..fd9ab6249 100644
--- a/gulpfile.js
+++ b/gulpfile.js
@@ -207,9 +207,11 @@ gulp.task('dev:copy',
// lint js
+const lintTargets = ['app/**/*.json', 'app/**/*.js', '!app/scripts/vendor/**/*.js', 'ui/**/*.js', 'mascara/src/*.js', 'mascara/server/*.js', '!node_modules/**', '!dist/firefox/**', '!docs/**', '!app/scripts/chromereload.js', '!mascara/test/jquery-3.1.0.min.js']
+
gulp.task('lint', function () {
// Ignoring node_modules, dist/firefox, and docs folders:
- return gulp.src(['app/**/*.js', '!app/scripts/vendor/**/*.js', 'ui/**/*.js', 'mascara/src/*.js', 'mascara/server/*.js', '!node_modules/**', '!dist/firefox/**', '!docs/**', '!app/scripts/chromereload.js', '!mascara/test/jquery-3.1.0.min.js'])
+ return gulp.src(lintTargets)
.pipe(eslint(fs.readFileSync(path.join(__dirname, '.eslintrc'))))
// eslint.format() outputs the lint results to the console.
// Alternatively use eslint.formatEach() (see Docs).
@@ -220,7 +222,7 @@ gulp.task('lint', function () {
});
gulp.task('lint:fix', function () {
- return gulp.src(['app/**/*.js', 'ui/**/*.js', 'mascara/src/*.js', 'mascara/server/*.js', '!node_modules/**', '!dist/firefox/**', '!docs/**', '!app/scripts/chromereload.js', '!mascara/test/jquery-3.1.0.min.js'])
+ return gulp.src(lintTargets)
.pipe(eslint(Object.assign(fs.readFileSync(path.join(__dirname, '.eslintrc')), {fix: true})))
.pipe(eslint.format())
.pipe(eslint.failAfterError())