bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: set -o pipefail inherited?


From: Chet Ramey
Subject: Re: set -o pipefail inherited?
Date: Sat, 06 Oct 2007 17:41:31 -0400
User-agent: Thunderbird 2.0.0.6 (Macintosh/20070728)

Dan Stromberg wrote:
> 
> Is there a way of getting "set -o pipefail" to be inherited from a shell
> to its subshell?  Or does each subshell have to set it again?

It depends on what kind of subshell you're talking about.  Subshells that
don't cause a new copy of the shell to be executed inherit nearly
everything.  Other subshells can inherit the values of shell options
by exporting the `SHELLOPTS' variable, as described in the man page.

Chet


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
                       Live Strong.  No day but today.
Chet Ramey, ITS, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]