Skip to content

Make shell.exec() treat process error return codes as shelljs errors#80

Merged
arturadib merged 1 commit intoshelljs:masterfrom
nilsbunger:master
Sep 9, 2013
Merged

Make shell.exec() treat process error return codes as shelljs errors#80
arturadib merged 1 commit intoshelljs:masterfrom
nilsbunger:master

Conversation

@nilsbunger
Copy link
Copy Markdown

This PR makes shell.exec() handle error return codes the same way as other shelljs errors -- by calling common.error(). Especially in fatal mode, this makes error handling of exec more consistent with other shelljs functions.

To test, I temporarily override process.exit(), then put it back... let me know if you have any better suggestions :)

@arturadib
Copy link
Copy Markdown
Collaborator

Looks great, thanks!

arturadib added a commit that referenced this pull request Sep 9, 2013
Make shell.exec() treat process error return codes as shelljs errors
@arturadib arturadib merged commit 31830d3 into shelljs:master Sep 9, 2013
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.

2 participants