Created
February 23, 2014 20:33
-
-
Save peebeebee/9176850 to your computer and use it in GitHub Desktop.
Exit shell on error
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh -e | |
/* | |
When this option is on, if a simple command fails for any of the reasons listed in Consequences of Shell Errors or returns an exit status value >0, and is not part of the compound list following a while, until, or if keyword, and is not a part of an AND or OR list, and is not a pipeline preceded by the ! reserved word, then the shell shall immediately exit. | |
*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment