> Yes, it's how bash has always behaved, at least back to bash-1.14 when
> I stopped looking.  Around bash-2.05, it changed to preserve the -e
> option when in Posix mode.

Is there any reason not to preserve it?

> That exception from default bash behavior is documented in the Posix
> Mode section of the texinfo manual.

Thanks, the bash manpage indeed references:

http://tiswww.case.edu/php/chet/bash/POSIX

(btw: would it make sense to add this as a manpage, e.g. as bash-posix?)

The relevant point seems to be:

 36. Subshells spawned to execute command substitutions inherit the
     value of the `-e' option from the parent shell.  When not in POSIX
     mode, Bash clears the `-e' option in such subshells.

Now I'm still curious why this isn't the default behaviour in bash?

Thanks,
Chris
-- 
echo mailto: NOSPAM !#$.'<*>'|sed 's. ..'|tr "<*> !#:2" org@fr33z3

Reply via email to