3 ms·
Well in that case it appears to be because of using "if foo" But that might have been your point in the first place :) I wasn't aware of the change in behavior
by graton 6y ago
Well in that case it appears to be because of using "if foo"
But that might have been your point in the first place :) I wasn't aware of the change in behavior with an 'if' statement.
As a note, trap ERR had the same behavior as 'set -e' from my quick check.
This dies:
#!/bin/bash
set -euE -o pipefail
FOO=/this/does/not/exist
foo() {
cd "$FOO"
echo hello
}
foo
echo We do not reach here