const gulp = require('gulp');
const gutil = require('gulp-util');
const eslint = require('gulp-eslint');
const excludeGitignore = require('gulp-exclude-gitignore');
const mocha = require('gulp-mocha');
const istanbul = require('gulp-istanbul');

gulp.task('linter', eslintCheck);
gulp.task('default', gulp.series('linter', gulp.series(istanbulCover, mochaTest)));

function eslintCheck() {
  return gulp.src('**/*.js')
    .pipe(excludeGitignore())
    .pipe(eslint())
    .pipe(eslint.format())
    .pipe(eslint.failAfterError());
}

function istanbulCover() {
  return gulp.src('generators/**/index.js')
    .pipe(istanbul({ includeUntested: true }))
    .pipe(istanbul.hookRequire());
}

function mochaTest() {
  return gulp.src('test/**/*.js')
    .pipe(mocha({reporter: 'spec'}))
    .once('error', function errorHandler(err) {
      gutil.log(gutil.colors.red('[Mocha]'), err.toString());
      process.exit(1);
    })
    .pipe(istanbul.writeReports());
}

@@ -619,17 +619,16 @@
 tanbul(%7B
- 
 includeU
@@ -640,17 +640,16 @@
 ed: true
- 
 %7D))%0A    
@@ -799,34 +799,14 @@
 r', 
-function errorHandler(err)
+err =%3E
  %7B%0A 

Fix linter errors