commit bash-20101124 snapshot

This commit is contained in:
Chet Ramey
2011-12-12 22:10:33 -05:00
parent 18d2df9102
commit adc6cff53c
69 changed files with 14151 additions and 780 deletions
+20 -18
View File
@@ -5,12 +5,12 @@
.\" Case Western Reserve University
.\" chet@po.cwru.edu
.\"
.\" Last Change: Mon Sep 6 22:07:38 EDT 2010
.\" Last Change: Mon Dec 6 22:25:10 EST 2010
.\"
.\" bash_builtins, strip all but Built-Ins section
.if \n(zZ=1 .ig zZ
.if \n(zY=1 .ig zY
.TH BASH 1 "2010 September 6" "GNU Bash-4.2"
.TH BASH 1 "2010 December 6" "GNU Bash-4.2"
.\"
.\" There's some problem with having a `@'
.\" in a tagged paragraph with the BSD man macros.
@@ -476,7 +476,7 @@ A \fItoken\fP that performs a control function. It is one of the following
symbols:
.RS
.PP
.if t \fB\(bv\(bv & && ; ;; ( ) | |& <newline>\fP
.if t \fB|| & && ; ;; ( ) | |& <newline>\fP
.if n \fB|| & && ; ;; ( ) | |& <newline>\fP
.RE
.PD
@@ -586,7 +586,7 @@ of the operators
.BR & ,
.BR && ,
or
.BR \(bv\(bv ,
.BR || ,
and optionally terminated by one of
.BR ; ,
.BR & ,
@@ -596,7 +596,7 @@ or
Of these list operators,
.B &&
and
.B \(bv\(bv
.B ||
have equal precedence, followed by
.B ;
and
@@ -617,7 +617,7 @@ command to terminate in turn. The return status is the
exit status of the last command executed.
.PP
AND and OR lists are sequences of one of more pipelines separated by the
\fB&&\fP and \fB\(bv\(bv\fP control operators, respectively.
\fB&&\fP and \fB||\fP control operators, respectively.
AND and OR lists are executed with left associativity.
An AND list has the form
.RS
@@ -633,7 +633,7 @@ returns an exit status of zero.
An OR list has the form
.RS
.PP
\fIcommand1\fP \fB\(bv\(bv\fP \fIcommand2\fP
\fIcommand1\fP \fB||\fP \fIcommand2\fP
.PP
.RE
.PP
@@ -763,8 +763,7 @@ and
.I expression2
are true.
.TP
.if t \fIexpression1\fP \fB\(bv\(bv\fP \fIexpression2\fP
.if n \fIexpression1\fP \fB||\fP \fIexpression2\fP
\fIexpression1\fP \fB||\fP \fIexpression2\fP
True if either
.I expression1
or
@@ -772,9 +771,7 @@ or
is true.
.PD
.LP
The \fB&&\fP and
.if t \fB\(bv\(bv\fP
.if n \fB||\fP
The \fB&&\fP and \fB||\fP
operators do not evaluate \fIexpression2\fP if the value of
\fIexpression1\fP is sufficient to determine the return value of
the entire conditional expression.
@@ -5508,10 +5505,14 @@ as if the "!\fIn\fP" history expansion had been specified.
.B
yank\-last\-arg (M\-.\^, M\-_\^)
Insert the last argument to the previous command (the last word of
the previous history entry). With an argument,
behave exactly like \fByank\-nth\-arg\fP.
the previous history entry).
With a numeric argument, behave exactly like \fByank\-nth\-arg\fP.
Successive calls to \fByank\-last\-arg\fP move back through the history
list, inserting the last argument of each line in turn.
list, inserting the last word (or the word specified by the argument to
the first call) of each line in turn.
Any numeric argument supplied to these successive calls determines
the direction to move through the history. A negative argument switches
the direction through the history (back or forward).
The history expansion facilities are used to extract the last argument,
as if the "!$" history expansion had been specified.
.TP
@@ -8476,8 +8477,8 @@ or
reserved words, part of any command executed in a
.B &&
or
.B \(bv\(bv
list except the command following the final \fB&&\fP or \fB\(bv\(bv\fP,
.B ||
list except the command following the final \fB&&\fP or \fB||\fP,
any command in a pipeline but the last,
or if the command's return value is
being inverted with
@@ -9262,6 +9263,7 @@ If the first argument is not a valid unary conditional operator, the expression
is false.
.TP
3 arguments
The following conditions are applied in the order listed.
If the second argument is one of the binary conditional operators listed above
under
.SM
@@ -9394,7 +9396,7 @@ part of the test in an
statement, part of a command executed in a
.B &&
or
.B \(bv\(bv
.B ||
list, or if the command's return value is
being inverted via
.BR ! .
+10 -5
View File
@@ -5508,10 +5508,14 @@ as if the "!\fIn\fP" history expansion had been specified.
.B
yank\-last\-arg (M\-.\^, M\-_\^)
Insert the last argument to the previous command (the last word of
the previous history entry). With an argument,
behave exactly like \fByank\-nth\-arg\fP.
the previous history entry).
With a numeric argument, behave exactly like \fByank\-nth\-arg\fP.
Successive calls to \fByank\-last\-arg\fP move back through the history
list, inserting the last argument of each line in turn.
list, inserting the last word (or the word specified by the argument to
the first call) of each line in turn.
Any numeric argument supplied to these successive calls determines
the direction to move through the history. A negative argument switches
the direction through the history (back or forward).
The history expansion facilities are used to extract the last argument,
as if the "!$" history expansion had been specified.
.TP
@@ -9210,6 +9214,7 @@ an argument of \fB\-\-\fP as signifying the end of options.
Expressions may be combined using the following operators, listed
in decreasing order of precedence.
The evaluation depends on the number of arguments; see below.
Operator precedence is used when there are five or more arguments.
.RS
.PD 0
.TP
@@ -9366,8 +9371,8 @@ is
.BR RETURN ,
the command
.I arg
is executed each time a shell function or a script executed with the
\fB.\fP or \fBsource\fP builtins finishes executing.
is executed each time a shell function or a script executed with
the \fB.\fP or \fBsource\fP builtins finishes executing.
.if t .sp 0.5
.if n .sp 1
If a
+1
View File
@@ -3239,6 +3239,7 @@ If the first argument is not a valid unary operator, the expression is
false.
@item 3 arguments
The following conditions are applied in the order listed.
If the second argument is one of the binary conditional
operators (@pxref{Bash Conditional Expressions}), the
result of the expression is the result of the binary test using the
+7 -13
View File
@@ -1717,7 +1717,7 @@ Bash uses the value of the variable formed from the rest of
expanded and that value is used in the rest of the substitution, rather
than the value of @var{parameter} itself.
This is known as @code{indirect expansion}.
The exceptions to this are the expansions of $@{!@var{prefix}@*}
The exceptions to this are the expansions of $@{!@var{prefix}@*@}
and $@{!@var{name}[@@]@}
described below.
The exclamation point must immediately follow the left brace in order to
@@ -3202,6 +3202,7 @@ be a @code{]}.
Expressions may be combined using the following operators, listed in
decreasing order of precedence.
The evaluation depends on the number of arguments; see below.
Operator precedence is used when there are five or more arguments.
@table @code
@item ! @var{expr}
@@ -6694,14 +6695,6 @@ the @sc{posix} standard, and include things like passing incorrect options,
redirection errors, variable assignment errors for assignments preceding
the command name, and so on.
@item
If @env{CDPATH} is set, the @code{cd} builtin will not implicitly
append the current directory to it. This means that @code{cd} will
fail if no valid directory name can be constructed from
any of the entries in @env{$CDPATH}, even if the a directory with
the same name as the name given as an argument to @code{cd} exists
in the current directory.
@item
A non-interactive shell exits with an error status if a variable
assignment error occurs when no command name follows the assignment
@@ -6709,6 +6702,11 @@ statements.
A variable assignment error occurs, for example, when trying to assign
a value to a readonly variable.
@item
A non-interactive shell exists with an error status if a variable
assignment error occurs in an assignment statement preceding a special
builtin, but not with any other simple command.
@item
A non-interactive shell exits with an error status if the iteration
variable in a @code{for} statement or the selection variable in a
@@ -6774,10 +6772,6 @@ constructed from @code{$PWD} and the directory name supplied as an argument
does not refer to an existing directory, @code{cd} will fail instead of
falling back to @var{physical} mode.
@item
When the @code{pwd} builtin is supplied the @option{-P} option, it resets
@code{$PWD} to a pathname containing no symlinks.
@item
The @code{pwd} builtin verifies that the value it prints is the same as the
current directory, even if it is not asked to check the file system with the