Make sure flake8 exits with an error status if linting does not pass.

This commit is contained in:
Christopher Charbonneau Wells 2018-10-13 17:00:42 -07:00
parent d943b54614
commit 8dea1f5b5b
1 changed files with 4 additions and 1 deletions

View File

@ -86,7 +86,10 @@ gulp.task('watch', watch);
function lint(cb) {
var command = ['run', 'flake8', '--exclude=etc,migrations,manage.py,node_modules,settings'];
command = command.concat(process.argv.splice(3));
spawn('pipenv', command, { stdio: 'inherit' }).on('exit', cb);
spawn('pipenv', command, { stdio: 'inherit' }).on('exit', function (code) {
if (code) process.exit(code);
cb();
});
pump([
gulp.src(config.watchConfig.stylesGlob),