5 ms·
Also, set -e is not a good flag to rely on, because it can really trip you up if you do anything at all that involves subshells, e.g.: set -e function foo
by joatmon-snoo 10y ago
Also, set -e is not a good flag to rely on, because it can really trip you up if you do anything at all that involves subshells, e.g.:
set -e
function foo {
false
echo foo
}
i=1
while [[ i -le 20 ]]; do
echo "$i $(foo)"
i=$((i+1))
done