Skip to content

errorHandlingStop | Added config to stop process on error#23

Open
Drintios wants to merge 8 commits intoskilld-labs:8.x-7.xfrom
Drintios:errorHandlingStop
Open

errorHandlingStop | Added config to stop process on error#23
Drintios wants to merge 8 commits intoskilld-labs:8.x-7.xfrom
Drintios:errorHandlingStop

Conversation

@Drintios
Copy link
Copy Markdown
Contributor

Added these to stop everything if error is found

@andypost
Copy link
Copy Markdown
Contributor

Comment thread STARTERKIT/gulpfile.js
}

// Convenience handler for error-level errors.
function onError(error) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can include the code for the function handleError inside the onError function, right?
as you are changing it's scope, but doesn't seems like it's required.

@Drintios
Copy link
Copy Markdown
Contributor Author

Drintios commented Aug 1, 2017

Added recommended changes by @pabloguerino

Still have one issue i tried to exit process on eslint error using eslint.results and errorCount to determine if error but every time it stops it hangs and i need to stop gulp manually.

To test this behavior you can add .pipe($.eslint.results(results => {onError(results);})); on the lint:js process

@andypost
Copy link
Copy Markdown
Contributor

andypost commented Aug 5, 2017

FYI tested current make lint in #31 and it works

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants