> However, because the error occurs in a pipe, it is lost, and the script continues despite the `set -e` at the start (which is a bug in itself).
It is not, Posix shell is supposed to behave that way. In bash, you can `set -o pipefail` to get the wanted behaviour.
> However, because the error occurs in a pipe, it is lost, and the script continues despite the `set -e` at the start (which is a bug in itself).
It is not, Posix shell is supposed to behave that way. In bash, you can `set -o pipefail` to get the wanted behaviour.