# When Bash Scripts Bite

DevFeed: [When Bash Scripts Bite](<https://devfeed.tech/articles/when-bash-scripts-bite-20238.md>)

Original publisher: [Read original article](<https://blog.janestreet.com/when-bash-scripts-bite/>)

Author: Todd Lubin

Published: 2017-05-11T00:00:00Z

Content type: article

Language: en

Sources: [Jane Street](<https://devfeed.tech/sources/jane-street.md>)

Topics: [Scripting, bash](<https://devfeed.tech/topics/scripting-bash.md>), [Bash](<https://devfeed.tech/topics/bash.md>), [Command-line interface](<https://devfeed.tech/topics/cli.md>)

Tags: [bash](<https://devfeed.tech/tags/bash.md>), [code](<https://devfeed.tech/tags/code.md>), [commands](<https://devfeed.tech/tags/commands.md>), [script](<https://devfeed.tech/tags/script.md>)

## AI overview

The article examines subtle failure modes of Bash's -e flag, including cases where commands do not cause a script to exit and where the flag is not passed to subshells in command substitutions. It argues that production shell scripts still require explicit reasoning about failure conditions.

## Source excerpt

There are abundant resources online trying to scare programmers away from using shell scripts. Most of them, if anything, succeed in convincing the reader to blindly put something that resembles