Skip to content

Instantly share code, notes, and snippets.

@GauntletWizard
Created May 23, 2016 06:48
Show Gist options
  • Save GauntletWizard/e16e30c24957c71d99552ae912dc5c61 to your computer and use it in GitHub Desktop.
Save GauntletWizard/e16e30c24957c71d99552ae912dc5c61 to your computer and use it in GitHub Desktop.
An example of how to use the pipefail option, and how it works.
set -e
set -x
true | false |true
echo "done"
set -o pipefail
true | false ||true
echo done
true | false && false
echo done
true | false | true
echo not done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment