- publishing free software manuals
GNU Bash Reference Manual
by Chet Ramey and Brian Fox
Paperback (6"x9"), 180 pages
ISBN 0954161777
RRP £19.95 ($29.95)

"An essential resource .... the most detailed coverage available for all aspects of Bash" --- Linux User and Developer Magazine (Issue 37, Mar 2004) Get a printed copy>>>

3.7.3 Command Execution Environment

The shell has an execution environment, which consists of the following:

When a simple command other than a builtin or shell function is to be executed, it is invoked in a separate execution environment that consists of the following. Unless otherwise noted, the values are inherited from the shell.

A command invoked in this separate environment cannot affect the shell's execution environment.

Command substitution, commands grouped with parentheses, and asynchronous commands are invoked in a subshell environment that is a duplicate of the shell environment, except that traps caught by the shell are reset to the values that the shell inherited from its parent at invocation. Builtin commands that are invoked as part of a pipeline are also executed in a subshell environment. Changes made to the subshell environment cannot affect the shell's execution environment.

If a command is followed by an ampersand ‘&’ and job control is not active, the default standard input for the command is the empty file ‘/dev/null’. Otherwise, the invoked command inherits the file descriptors of the calling shell as modified by redirections.

ISBN 0954161777GNU Bash Reference ManualSee the print edition