Imported from ../bash-2.05a.tar.gz.

This commit is contained in:
Jari Aalto
2009-09-12 16:46:54 +00:00
parent 28ef6c316f
commit f73dda092b
303 changed files with 37057 additions and 28800 deletions
+157 -72
View File
@@ -1,4 +1,4 @@
This is the Bash FAQ, version 3.11, for Bash version 2.05.
This is the Bash FAQ, version 3.17, for Bash version 2.05a.
This document contains a set of frequently-asked questions concerning
Bash, the GNU Bourne-Again Shell. Bash is a freely-available command
@@ -36,8 +36,8 @@ A10) What is the bash `posix mode'?
Section B: The latest version
B1) What's new in version 2.05?
B2) Are there any user-visible incompatibilities between bash-2.05 and
B1) What's new in version 2.05a?
B2) Are there any user-visible incompatibilities between bash-2.05a and
bash-1.14.7?
Section C: Differences from other Unix shells
@@ -134,22 +134,23 @@ of Case Western Reserve University.
A2) What's the latest version?
The latest version is 2.05, first made available on Monday, 9 April 2001.
The latest version is 2.05a, first made available on Thursday, 15
November, 2001.
A3) Where can I get it?
Bash is the GNU project's shell, and so is available from the
master GNU archive site, ftp.gnu.org, and its mirrors. The
latest version is also available for FTP from ftp.cwru.edu.
The following URLs tell how to get version 2.05:
The following URLs tell how to get version 2.05a:
ftp://ftp.gnu.org/pub/gnu/bash/bash-2.05.tar.gz
ftp://ftp.cwru.edu/pub/bash/bash-2.05.tar.gz
ftp://ftp.gnu.org/pub/gnu/bash/bash-2.05a.tar.gz
ftp://ftp.cwru.edu/pub/bash/bash-2.05a.tar.gz
Formatted versions of the documentation are available with the URLs:
ftp://ftp.gnu.org/pub/gnu/bash/bash-doc-2.05.tar.gz
ftp://ftp.cwru.edu/pub/bash/bash-doc-2.05.tar.gz
ftp://ftp.gnu.org/pub/gnu/bash/bash-doc-2.05a.tar.gz
ftp://ftp.cwru.edu/pub/bash/bash-doc-2.05a.tar.gz
A4) On what machines will bash run?
@@ -161,13 +162,17 @@ itself accordingly, using a script created by GNU autoconf.
More information appears in the file `INSTALL' in the distribution.
The Bash web page (http://cnswww.cns.cwru.edu/~chet/bash/bashtop.html)
explains how to obtain binary versions of bash for most of the major
commercial Unix systems.
A5) Will bash run on operating systems other than Unix?
Configuration specifics for Unix-like systems such as QNX and
LynxOS are included in the distribution. Bash-2.05 should
compile and run on Minix 2.0 (patches were contributed), but I
don't believe anyone has built bash-2.x on earlier Minix versions
yet.
LynxOS are included in the distribution. Bash-2.05 and later
versions should compile and run on Minix 2.0 (patches were
contributed), but I don't believe anyone has built bash-2.x on
earlier Minix versions yet.
Bash has been ported to versions of Windows implementing the Win32
programming interface. This includes Windows 95 and Windows NT.
@@ -179,10 +184,10 @@ http://sourceware.cygnus.com/cygwin
Cygnus originally ported bash-1.14.7, and that port was part of their
early GNU-Win32 (the original name) releases. Cygnus has also done a
port of bash-2.04 to the CYGWIN environment, and it is available as
port of bash-2.05 to the CYGWIN environment, and it is available as
part of their current release.
Bash-2.05 should require no local Cygnus changes to build and run under
Bash-2.05a should require no local Cygnus changes to build and run under
CYGWIN.
The Cygnus port works only on Intel machines. There is a port of bash
@@ -190,30 +195,21 @@ The Cygnus port works only on Intel machines. There is a port of bash
ftp://ftp.gnustep.org//pub/win32/bash-alpha-nt-1.01.tar.gz
DJ Delorie has a port of bash-1.14.7 which runs under MS-DOS, as part
DJ Delorie has a port of bash-2.x which runs under MS-DOS, as part
of the DJGPP project. For more information on the project, see
http://www.delorie.com/djgpp/
I have been told that the original DJGPP port was done by Daisuke Aoyama.
I picked up a binary of bash-1.14.7 that is purported to work with
the DJGPP V2 environment from
Mark Elbrecht <snowball3@bigfoot.com> has sent me notice that bash-2.04
is available for DJGPP V2. The files are available as:
ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2gnu/bsh1147b.zip
ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2gnu/bsh204b.zip binary
ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2gnu/bsh204d.zip documentation
ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2gnu/bsh204s.zip source
The corresponding source is
ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2gnu/bsh1147s.zip
Mark Elbrecht <snowball3@bigfoot.com> has sent me notice that bash-2.03
has become available for DJGPP V2. The files are available as:
ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2gnu/bsh203b.zip binary
ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2gnu/bsh203d.zip documentation
ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2gnu/bsh203s.zip source
Mark has begun to work with bash-2.04.
Mark has begun to work with bash-2.05, but I don't know the status.
Ports of bash-1.12 and bash-2.0 are available for OS/2 from
@@ -285,8 +281,9 @@ slightly different.
If you cannot change your login shell in the password file to bash, you
will have to (apparently) live with CDE using the shell in the password
file to run its startup scripts. If you have changed your shell to bash,
there is code in the CDE startup files (on Solaris, at least) to do the
right thing.
there is code in the CDE startup files (on Solaris, at least) that attempts
to do the right thing. It is, however, often broken, and may require that
you use the $BASH_ENV trick described below.
`dtterm' claims to use $SHELL as the default program to start, so if you
can change $SHELL in the CDE startup files, you should be able to use bash
@@ -304,6 +301,16 @@ CDE by testing the value of the DT variable:
[ -f /usr/gnu/bin/bash ] && exec /usr/gnu/bin/bash --login
fi
If CDE starts its shells non-interactively during login, the login shell
startup files (~/.profile, ~/.bash_profile) will not be sourced at login.
To get around this problem, append a line similar to the following to your
~/.dtprofile:
BASH_ENV=${HOME}/.bash_profile ; export BASH_ENV
and add the following line to the beginning of ~/.bash_profile:
unset BASH_ENV
A8) I just changed my login shell to bash, and now I can't FTP into my
machine. Why not?
@@ -350,6 +357,12 @@ line editing. Only vi-style line editing commands have been
standardized; emacs editing commands were left out due to
objections.
The Open Group has made an older version of its Single Unix
Specification (version 2), which is very similar to POSIX.2,
available on the web at
http://www.opengroup.org/onlinepubs/007908799/
A10) What is the bash `posix mode'?
Although bash is an implementation of the POSIX.2 shell
@@ -367,12 +380,48 @@ Reference Manual.
Section B: The latest version
B1) What's new in version 2.05?
B1) What's new in version 2.05a?
Bash-2.05 contains the following new features (see the manual page for
complete descriptions and the CHANGES and NEWS files in the bash-2.05
The raison d'etre for bash-2.05a is to make an intermediate release
containing principally bug fixes (some very good work was done and
contributed after bash-2.05 was released) available before I start to
work on the major new features to be available in the next release
(bash-2.06 or bash-3.0 or whatever I tag it). As such, there are
only a few relatively minor new features.
Bash-2.05a contains the following new features (see the manual page for
complete descriptions and the CHANGES and NEWS files in the bash-2.05a
distribution):
o The `printf' builtin has undergone major work
o There is a new read-only `shopt' option: login_shell, which is set by
login shells and unset otherwise
o New `\A' prompt string escape sequence; expanding to time in 24-hour
HH:MM format
o New `-A group/-g' option to complete and compgen; goes group name
completion
o New [+-]O invocation option to set and unset `shopt' options at startup
o ksh-like `ERR' trap
o `for' loops now allow empty word lists after the `in' reserved word
o new `hard' and `soft' arguments for the `ulimit' builtin
o Readline can be configured to place the user at the same point on the line
when retrieving commands from the history list
o Readline can be configured to skip `hidden' files (filenames with a leading
`.' on Unix) when performing completion
A short feature history dating from bash-2.0:
Bash-2.05 introduced the following new features:
o This version has once again reverted to using locales and strcoll(3) when
processing pattern matching bracket expressions, as POSIX requires.
o Added a new `--init-file' invocation argument as a synonym for `--rcfile',
@@ -396,8 +445,6 @@ o When `set' is called without options, it prints function defintions in a
`declare -p' as well. This only happens when the shell is not in POSIX
mode, since POSIX.2 forbids this behavior.
A short feature history dating from bash-2.0:
Bash-2.04 introduced the following new features:
o Programmable word completion with the new `complete' and `compgen' builtins;
@@ -523,11 +570,13 @@ grammar tighter and smaller (66 reduce-reduce conflicts gone)
lots of code now smaller and faster
test suite greatly expanded
B2) Are there any user-visible incompatibilities between bash-2.05 and
B2) Are there any user-visible incompatibilities between bash-2.05a and
bash-1.14.7?
There are a few incompatibilities between version 1.14.7 and version 2.05.
They are detailed in the file COMPAT in the bash-2.05 distribution.
There are a few incompatibilities between version 1.14.7 and version 2.05a.
They are detailed in the file COMPAT in the bash-2.05a distribution. That
file is not meant to be all-encompassing; send mail to bash-maintainers@gnu.org
if you find something that's not mentioned there.
Section C: Differences from other Unix shells
@@ -539,6 +588,7 @@ completely.
Things bash has that sh does not:
long invocation options
[+-]O invocation option
`!' reserved word to invert pipeline return value
`time' reserved word to time pipelines and shell builtins
the `function' reserved word
@@ -564,13 +614,14 @@ Things bash has that sh does not:
SHELLOPTS, OPTERR, HOSTFILE, TMOUT, FUNCNAME, histchars,
auto_resume
DEBUG trap
ERR trap
variable arrays with new compound assignment syntax
redirections: <>, &>, >|
prompt string special char translation and variable expansion
auto-export of variables in initial environment
command search finds functions before builtins
bash return builtin will exit a file sourced with `.'
builtins: cd -/-L/-P, exec -l/-c/-a, echo -e/-E, hash -p.
builtins: cd -/-L/-P, exec -l/-c/-a, echo -e/-E, hash -p/-t.
export -n/-f/-p/name=value, pwd -L/-P,
read -e/-p/-a/-t/-n/-d/-s,
readonly -a/-f/name=value, trap -l, set +o,
@@ -638,6 +689,7 @@ C2) How does bash differ from the Korn shell, version ksh88?
Things bash has or uses that ksh88 does not:
long invocation options
[-+]O invocation option
`!' reserved word
arithmetic for command: for ((expr1 ; expr2; expr3 )); do list; done
posix mode and posix conformance
@@ -674,11 +726,11 @@ Things bash has or uses that ksh88 does not:
case-insensitive pattern matching and globbing
`**' arithmetic operator to do exponentiation
redirection to /dev/fd/N, /dev/stdin, /dev/stdout, /dev/stderr
arrays of unlimited size
Things ksh88 has or uses that bash does not:
tracked aliases
tracked aliases (alias -t)
variables: ERRNO, FPATH, EDITOR, VISUAL
trap on ERR
co-processes (|&, >&p, <&p)
weirdly-scoped functions
typeset +f to list all function names without definitions
@@ -686,7 +738,10 @@ Things ksh88 has or uses that bash does not:
builtins: alias -x, cd old new, fc -e -, newgrp, print,
read -p/-s/-u/var?prompt, set -A/-o gmacs/
-o bgnice/-o markdirs/-o nolog/-o trackall/-o viraw/-s,
typeset -H/-L/-R/-A/-ft/-fu/-fx/-l/-u/-t, whence
typeset -H/-L/-R/-Z/-A/-ft/-fu/-fx/-l/-u/-t, whence
using environment to pass attributes of exported variables
arithmetic evaluation done on arguments to some builtins
reads .profile from $PWD when invoked as login shell
Implementation differences:
ksh runs last command of a pipeline in parent shell context
@@ -694,12 +749,14 @@ Implementation differences:
bash has fixed startup file for all interactive shells; ksh reads $ENV
bash has exported functions
bash command search finds functions before builtins
bash waits for all commands in pipeline to exit before returning status
emacs-mode editing has some slightly different key bindings
C3) Which new features in ksh-93 are not in bash, and which are?
New things in ksh-93 not in bash-2.05:
New things in ksh-93 not in bash-2.05a:
associative arrays
floating point arithmetic
floating point arithmetic and variables
math library functions
${!name[sub]} name of subscript for associative array
`.' is allowed in variable names to create a hierarchical namespace
@@ -709,13 +766,24 @@ New things in ksh-93 not in bash-2.05:
typeset -n and `nameref' variables
KEYBD trap
variables: .sh.edchar, .sh.edmode, .sh.edcol, .sh.edtext, .sh.version,
.sh.name, .sh.subscript, .sh.value, HISTEDIT
backreferences in pattern matching
.sh.name, .sh.subscript, .sh.value, .sh.match, HISTEDIT
backreferences in pattern matching (\N)
`&' operator in pattern lists for matching
print -f (bash uses printf)
`fc' has been renamed to `hist'
`.' can execute shell functions
exit statuses between 0 and 255
set -o pipefail
`+=' variable assignment operator
TMOUT is default timeout for `read' and `select'
<&N- and >&N- redirections (combination dup and close)
FPATH and PATH mixing
getopts -a
-I invocation option
DEBUG trap now executed before each simple command, instead of after
printf %H, %P, %T, %Z modifiers, output base for %d
New things in ksh-93 present in bash-2.04:
New things in ksh-93 present in bash-2.05a:
for (( expr1; expr2; expr3 )) ; do list; done - arithmetic for command
?:, ++, --, `expr1 , expr2' arithmetic operators
expansions: ${!param}, ${param:offset[:len]}, ${param/pat[/str]},
@@ -1041,6 +1109,16 @@ this.
This is the general approach -- in most cases you will not need to
set $IFS to a different value.
Some other user-supplied alternatives include:
read A B C D << HERE
$(IFS=.; echo $(/usr/local/bin/ipaddr))
HERE
and, where process substitution is available,
read A B C D < <(IFS=.; echo $(/usr/local/bin/ipaddr))
E5) I have a bunch of shell scripts that use backslash-escaped characters
in arguments to `echo'. Bash doesn't interpret these characters. Why
not, and how can I make it understand them?
@@ -1057,7 +1135,7 @@ them.
There is a configuration option that will make bash behave like
the System V echo and interpret things like `\t' by default. Run
configure with the --enable-usg-echo-default option to turn this
configure with the --enable-xpg-echo-default option to turn this
on. Be aware that this will cause some of the tests run when you
type `make tests' to fail.
@@ -1101,11 +1179,12 @@ bash:
( cd $d && ${MAKE} ${MFLAGS} clean )
done
This is a syntax error. If the reserved word `in' is present, a word must
follow it before the semicolon or newline. The language in the manual page
referring to the list of words being empty refers to the list after it is
expanded. There must be at least one word following the `in' when the
construct is parsed.
In versions of bash before bash-2.05a, this was a syntax error. If the
reserved word `in' was present, a word must follow it before the semicolon
or newline. The language in the manual page referring to the list of words
being empty referred to the list after it is expanded. These versions of
bash required that there be at least one word following the `in' when the
construct was parsed.
The idiomatic Makefile solution is something like:
@@ -1116,11 +1195,9 @@ subdirs-clean:
( cd $$d && ${MAKE} ${MFLAGS} clean ) \
done
The POSIX.2 interpretation committee has considered this issue and declared
that the bash implemenation is correct, according to the standard:
http://www.pasc.org/interps/unofficial/db/p1003.2/pasc-1003.2-169.html
The latest drafts of the updated POSIX standard have changed this: the
word list is no longer required. Bash versions 2.05a and later accept
the new syntax.
E8) Why does the arithmetic evaluation code complain about `08'?
@@ -1143,11 +1220,12 @@ honoring the current locale setting when processing ranges within pattern
matching bracket expressions ([A-Z]). This is what POSIX.2 and SUSv2/XPG5
specify.
The behavior of the matcher in bash-2.05 depends on the current LC_COLLATE
setting. Setting this variable to `C' or `POSIX' will result in the
traditional behavior ([A-Z] matches all uppercase ASCII characters).
Many other locales, including the en_US locale (the default on many US
versions of Linux) collate the upper and lower case letters like this:
The behavior of the matcher in bash-2.05 and later versions depends on the
current LC_COLLATE setting. Setting this variable to `C' or `POSIX' will
result in the traditional behavior ([A-Z] matches all uppercase ASCII
characters). Many other locales, including the en_US locale (the default
on many US versions of Linux) collate the upper and lower case letters like
this:
AaBb...Zz
@@ -1279,7 +1357,7 @@ comp.unix.shell). While most commands of the form
can be converted to `< file command', shell control structures such as
loops and subshells require `command < file'.
The file CWRU/sh-redir-hack in the bash-2.05 distribution is an
The file CWRU/sh-redir-hack in the bash-2.05a distribution is an
(unofficial) patch to parse.y that will modify the grammar to
support this construct. It will not apply with `patch'; you must
modify parse.y by hand. Note that if you apply this, you must
@@ -1396,6 +1474,9 @@ before `eval' is executed. In versions of bash later than bash-2.0,
does the same thing.
This is not the same thing as ksh93 `nameref' variables, though the syntax
is similar. I may add namerefs in a future bash version.
G4) How can I make the bash `time' reserved word print timing output that
looks like the output from my system's /usr/bin/time?
@@ -1524,14 +1605,14 @@ or on the web.
H3) What's coming in future versions?
These are features I plan to include in a future version of bash.
These are features I hope to include in a future version of bash.
a bash debugger (a minimally-tested version is included with bash-2.05)
a better bash debugger (a minimally-tested version is included with bash-2.05a)
associative arrays
changes to the DEBUG trap to be compatible with ksh93 (which runs the
trap before each simple command, instead of after each one like previous
versions)
an implementation of the ksh-like ERR trap
co-processes, but with a new-style syntax that looks like function declaration
H4) What's on the bash `wish list' for future versions?
@@ -1545,11 +1626,15 @@ date-stamped command history
a bash programmer's guide with a chapter on creating loadable builtins
a better loadable interface to perl with access to the shell builtins and
variables (contributions gratefully accepted)
ksh93-like `nameref' variables
ksh93-like `+=' variable assignment operator
ksh93-like `xx.yy' variables (including some of the .sh.* variables) and
associated disipline functions
Some of the new ksh93 pattern matching operators, like backreferencing
H5) When will the next release appear?
The next version will appear sometime in 2001 or 2002. Never make
predictions.
The next version will appear sometime in 2002. Never make predictions.
This document is Copyright 1995-2001 by Chester Ramey.
+52 -49
View File
@@ -32,13 +32,16 @@ infodir = @infodir@
# set this to a directory name to have the HTML files installed
htmldir = @htmldir@
# Support an alternate destination root directory for package building
DESTDIR =
mandir = @mandir@
manpfx = man
man1ext = 1
man1dir = $(mandir)/$(manpfx)$(man1ext)
man3ext = 3
man3dir = $(mandir)/$(manpfx)$(man3ext)
man1ext = .1
man1dir = $(mandir)/$(manpfx)1
man3ext = .3
man3dir = $(mandir)/$(manpfx)3
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
@@ -167,6 +170,51 @@ article.ps: article.ms
$(MAN2HTML): ${topdir}/support/man2html.c
-( cd ${BUILD_DIR}/support ; ${MAKE} ${MFLAGS} man2html)
clean:
$(RM) *.aux *.bak *.cp *.fn *.ky *.log *.pg *.toc *.tp *.vr *.cps \
*.pgs *.bt *.bts *.rw *.rws *.fns *.kys *.tps *.vrs *.o
${RM} core *.core
distclean mostlyclean: clean
$(RM) Makefile
maintainer-clean: clean
${RM} ${PSFILES} ${DVIFILES} ${INFOFILES} ${MAN0FILES} ${HTMLFILES}
${RM} ${CREATED_FAQ}
$(RM) Makefile
installdirs:
-test -d $(man1dir) || $(SHELL) ${MKDIRS} $(DESTDIR)$(man1dir)
-test -d $(infodir) || $(SHELL) ${MKDIRS} $(DESTDIR)$(infodir)
-if test -n "$(htmldir)" ; then \
test -d $(htmldir) || $(SHELL) ${MKDIRS} $(DESTDIR)$(htmldir) ; \
fi
install: info installdirs
-$(INSTALL_DATA) $(srcdir)/bash.1 $(DESTDIR)$(man1dir)/bash${man1ext}
-$(INSTALL_DATA) $(srcdir)/bashbug.1 $(DESTDIR)$(man1dir)/bashbug${man1ext}
# uncomment the next line to install the builtins man page
# -$(INSTALL_DATA) $(srcdir)/builtins.1 $(DESTDIR)$(man1dir)/bash_builtins${man1ext}
-$(INSTALL_DATA) $(srcdir)/bashref.info $(DESTDIR)$(infodir)/bash.info
# run install-info if it is present to update the info directory
if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
install-info --dir-file=$(DESTDIR)$(infodir)/dir $(DESTDIR)$(infodir)/bash.info; \
else true; fi
# if htmldir is set, install the html files into that directory
-if test -n "${htmldir}" ; then \
$(INSTALL_DATA) $(srcdir)/bash.html $(DESTDIR)$(htmldir) ; \
$(INSTALL_DATA) $(srcdir)/bashref.html $(DESTDIR)$(htmldir) ; \
fi
uninstall:
-$(RM) $(DESTDIR)$(man1dir)/bash${man1ext} $(DESTDIR)$(man1dir)/bashbug${man1ext}
$(RM) $(DESTDIR)$(infodir)/bash.info
-if test -n "$(htmldir)" ; then \
$(RM) $(DESTDIR)$(htmldir)/bash.html ; \
$(RM) $(DESTDIR)$(htmldir)/bashref.html ; \
fi
# for use by chet
CREATED_FAQ = faq.news faq.news2 faq.mail faq.version
faq: ${CREATED_FAQ}
@@ -195,51 +243,6 @@ faq.mail: FAQ faq.headers.mail faq.version
$(RM) $@
cat faq.headers.mail faq.version FAQ > $@
clean:
$(RM) *.aux *.bak *.cp *.fn *.ky *.log *.pg *.toc *.tp *.vr *.cps \
*.pgs *.bt *.bts *.rw *.rws *.fns *.kys *.tps *.vrs *.o
${RM} core *.core
distclean mostlyclean: clean
$(RM) Makefile
maintainer-clean: clean
${RM} ${PSFILES} ${DVIFILES} ${INFOFILES} ${MAN0FILES} ${HTMLFILES}
${RM} ${CREATED_FAQ}
$(RM) Makefile
installdirs:
-test -d $(man1dir) || $(SHELL) ${MKDIRS} $(man1dir)
-test -d $(infodir) || $(SHELL) ${MKDIRS} $(infodir)
-if [ -n "$(htmldir)" ]; then \
test -d $(htmldir) || $(SHELL) ${MKDIRS} $(htmldir) ; \
fi
install: info installdirs
-$(INSTALL_DATA) $(srcdir)/bash.1 $(man1dir)/bash.${man1ext}
-$(INSTALL_DATA) $(srcdir)/bashbug.1 $(man1dir)/bashbug.${man1ext}
# uncomment the next line to install the builtins man page
# $(INSTALL_DATA) $(srcdir)/builtins.1 $(man1dir)/bash_builtins.${man1ext}
-$(INSTALL_DATA) $(srcdir)/bashref.info $(infodir)/bash.info
# run install-info if it is present to update the info directory
if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
install-info --dir-file=$(infodir)/dir $(infodir)/bash.info; \
else true; fi
# if htmldir is set, install the html files into that directory
-if [ -n "${htmldir}" ]; then \
$(INSTALL_DATA) $(srcdir)/bash.html $(htmldir) ; \
$(INSTALL_DATA) $(srcdir)/bashref.html $(htmldir) ; \
fi
uninstall:
-$(RM) $(man1dir)/bash.${man1ext} $(man1dir)/bashbug.${man1ext}
$(RM) $(infodir)/bash.info
-if [ -n "$(htmldir)" ]; then \
$(RM) $(htmldir)/bash.html ; \
$(RM) $(htmldir)/bashref.html ; \
fi
# for use by chet
inst: bashref.texi
$(SHELL) ./mkinstall
cmp -s INSTALL ../INSTALL || mv INSTALL ../INSTALL
+628 -507
View File
File diff suppressed because it is too large Load Diff
+360 -262
View File
File diff suppressed because it is too large Load Diff
+190 -105
View File
@@ -5,13 +5,13 @@
@c %**end of header
@ignore
Last Change: Wed Mar 28 14:48:38 EST 2001
Last Change: Tue Nov 13 12:48:51 EST 2001
@end ignore
@set EDITION 2.5
@set VERSION 2.05
@set UPDATED 28 Mar 2001
@set UPDATE-MONTH Mar 2001
@set EDITION 2.5a
@set VERSION 2.05a
@set UPDATED 13 November 2001
@set UPDATE-MONTH November 2001
@iftex
@finalout
@@ -36,7 +36,7 @@ This is Edition @value{EDITION}, last updated @value{UPDATED},
of @cite{The GNU Bash Reference Manual},
for @code{Bash}, Version @value{VERSION}.
Copyright (C) 1991-1999 Free Software Foundation, Inc.
Copyright (C) 1991-2001 Free Software Foundation, Inc.
Permission is granted to make and distribute verbatim copies of
this manual provided the copyright notice and this permission notice
@@ -267,7 +267,8 @@ or one of the following:
@item exit status
@cindex exit status
The value returned by a command to its caller.
The value returned by a command to its caller. The value is restricted
to eight bits, so the maximum value is 255.
@item field
@cindex field
@@ -542,11 +543,11 @@ backslash
@item \'
single quote
@item \@var{nnn}
the character whose @code{ASCII} code is the octal value @var{nnn}
(one to three digits)
@item \x@var{nnn}
the character whose @code{ASCII} code is the hexadecimal value @var{nnn}
the eight-bit character whose value is the octal value @var{nnn}
(one to three digits)
@item \x@var{HH}
the eight-bit character whose value is the hexadecimal value @var{HH}
(one or two hex digits)
@end table
@noindent
@@ -556,6 +557,9 @@ been present.
@node Locale Translation
@subsubsection Locale-Specific Translation
@cindex localization
@cindex internationalization
@cindex native languages
@cindex translation, native languages
A double-quoted string preceded by a dollar sign (@samp{$}) will cause
the string to be translated according to the current locale.
@@ -564,12 +568,17 @@ is ignored.
If the string is translated and replaced, the replacement is
double-quoted.
@vindex LC_MESSAGES
@vindex TEXTDOMAIN
@vindex TEXTDOMAINDIR
Some systems use the message catalog selected by the @env{LC_MESSAGES}
shell variable. Others create the name of the message catalog from the
value of the @env{TEXTDOMAIN} shell variable, possibly adding a
suffix of @samp{.mo}. If you use the @env{TEXTDOMAIN} variable, you
may need to set the @env{TEXTDOMAINDIR} variable to the location of
the message catalog files.
the message catalog files. Still others use both variables in this
fashion:
@env{TEXTDOMAINDIR}/@env{LC_MESSAGES}/LC_MESSAGES/@env{TEXTDOMAIN}.mo.
@node Comments
@subsection Comments
@@ -640,9 +649,9 @@ The format for a pipeline is
@end example
@noindent
The output of each command in the pipeline is connected to the input of
the next command. That is, each command reads the previous command's
output.
The output of each command in the pipeline is connected via a pipe
to the input of the next command.
That is, each command reads the previous command's output.
The reserved word @code{time} causes timing statistics
to be printed for the pipeline once it finishes.
@@ -891,7 +900,7 @@ Any other value read causes @var{name} to be set to null.
The line read is saved in the variable @env{REPLY}.
The @var{commands} are executed after each selection until a
@code{break} or @code{return} command is executed, at which
@code{break} command is executed, at which
point the @code{select} command completes.
Here is an example that allows the user to pick a filename from the
@@ -1063,7 +1072,7 @@ call. When a function completes, the values of the
positional parameters and the special parameter @samp{#}
are restored to the values they had prior to the function's
execution. If a numeric argument is given to @code{return},
that is the function's return status; otherwise the functions's
that is the function's return status; otherwise the function's
return status is the exit status of the last command executed
before the @code{return}.
@@ -1090,6 +1099,9 @@ It can be a @code{name}, a number, or one of the special characters
listed below.
For the shell's purposes, a @var{variable} is a parameter denoted by a
@code{name}.
A variable has a @var{value} and zero or more @var{attributes}.
Attributes are assigned using the @code{declare} builtin command
(see the description of the @code{declare} builtin in @ref{Bash Builtins}).
A parameter is set if it has been assigned a value. The null string is
a valid value. Once a variable is set, it may be unset only by using
@@ -1105,13 +1117,15 @@ is not given, the variable is assigned the null string. All
@var{value}s undergo tilde expansion, parameter and variable expansion,
command substitution, arithmetic expansion, and quote
removal (detailed below). If the variable has its @code{integer}
attribute set (see the description of the @code{declare} builtin in
@ref{Bash Builtins}), then @var{value}
attribute set, then @var{value}
is subject to arithmetic expansion even if the @code{$((@dots{}))}
expansion is not used (@pxref{Arithmetic Expansion}).
Word splitting is not performed, with the exception
of @code{"$@@"} as explained below.
Filename expansion is not performed.
Assignment statements may also appear as arguments to the
@code{declare}, @code{typeset}, @code{export}, @code{readonly},
and @code{local} builtin commands.
@node Positional Parameters
@subsection Positional Parameters
@@ -1870,13 +1884,13 @@ File descriptor 2 is duplicated.
@item /dev/tcp/@var{host}/@var{port}
If @var{host} is a valid hostname or Internet address, and @var{port}
is an integer port number, Bash attempts to open a TCP connection
to the corresponding socket.
is an integer port number or service name, Bash attempts to open a TCP
connection to the corresponding socket.
@item /dev/udp/@var{host}/@var{port}
If @var{host} is a valid hostname or Internet address, and @var{port}
is an integer port number, Bash attempts to open a UDP connection
to the corresponding socket.
is an integer port number or service name, Bash attempts to open a UDP
connection to the corresponding socket.
@end table
@@ -2230,6 +2244,11 @@ 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 a @samp{&} and job control is not active, the
default standard input for the command is the empty file @file{/dev/null}.
Otherwise, the invoked command inherits the file descriptors of the calling
shell as modified by redirections.
@node Environment
@subsection Environment
@cindex environment
@@ -2319,8 +2338,8 @@ command substitution ignore the keyboard-generated job control signals
@code{SIGTTIN}, @code{SIGTTOU}, and @code{SIGTSTP}.
The shell exits by default upon receipt of a @code{SIGHUP}.
Before exiting, it resends the @code{SIGHUP} to all jobs, running
or stopped.
Before exiting, an interactive shell resends the @code{SIGHUP} to
all jobs, running or stopped.
Stopped jobs are sent @code{SIGCONT} to ensure that they receive
the @code{SIGHUP}.
To prevent the shell from sending the @code{SIGHUP} signal to a
@@ -2351,7 +2370,11 @@ a file is used as the first non-option argument when invoking Bash,
and neither the @option{-c} nor @option{-s} option is supplied
(@pxref{Invoking Bash}),
Bash reads and executes commands from the file, then exits. This
mode of operation creates a non-interactive shell. When Bash runs
mode of operation creates a non-interactive shell. The shell first
searches for the file in the current directory, and looks in the
directories in @env{$PATH} if not found there.
When Bash runs
a shell script, it sets the special parameter @code{0} to the name
of the file, rather than the name of the shell, and the positional
parameters are set to the remaining arguments, if any are given.
@@ -2614,7 +2637,7 @@ If @code{getopts} is silent, then a colon (@samp{:}) is placed in
@item hash
@btindex hash
@example
hash [-r] [-p @var{filename}] [@var{name}]
hash [-r] [-p @var{filename}] [-t] [@var{name}]
@end example
Remember the full pathnames of commands specified as @var{name} arguments,
so they need not be searched for on subsequent invocations.
@@ -2623,6 +2646,10 @@ The commands are found by searching through the directories listed in
The @option{-p} option inhibits the path search, and @var{filename} is
used as the location of @var{name}.
The @option{-r} option causes the shell to forget all remembered locations.
If the @option{-t} option is supplied, the full pathname to which each
@var{name} corresponds is printed. If multiple @var{name} arguments are
supplied with @option{-t} the @var{name} is printed before the hashed
full pathname.
If no arguments are given, information about remembered commands is printed.
The return status is zero unless a @var{name} is not found or an invalid
option is supplied.
@@ -2671,7 +2698,7 @@ This may also be used to terminate execution of a script being executed
with the @code{.} (or @code{source}) builtin, returning either @var{n} or
the exit status of the last command executed within the script as the exit
status of the script.
The return status is false if @code{return} is used outside a function
The return status is non-zero if @code{return} is used outside a function
and not during the execution of a script by @code{.} or @code{source}.
@item shift
@@ -2795,6 +2822,12 @@ If a @var{sigspec}
is @code{0} or @code{EXIT}, @var{arg} is executed when the shell exits.
If a @var{sigspec} is @code{DEBUG}, the command @var{arg} is executed
after every simple command.
If a @var{sigspec} is @code{ERR}, the command @var{arg}
is executed whenever a simple command has a non-zero exit status.
The @code{ERR} trap is not executed if the failed command is part of an
@code{until} or @code{while} loop, part of an @code{if} statement,
part of a @code{&&} or @code{||} list, or if the command's return
status is being inverted using @code{!}.
The @option{-l} option causes the shell to print a list of signal names
and their corresponding numbers.
@@ -3074,11 +3107,11 @@ vertical tab
@item \\
backslash
@item \@var{nnn}
the character whose @code{ASCII} code is the octal value @var{nnn}
(one to three digits)
@item \x@var{nnn}
the character whose @code{ASCII} code is the hexadecimal value @var{nnn}
the eight-bit character whose value is the octal value @var{nnn}
(one to three digits)
@item \x@var{HH}
the eight-bit character whose value is the hexadecimal value @var{HH}
(one or two hex digits)
@end table
@item enable
@@ -3377,6 +3410,11 @@ If enabled, and the @code{cmdhist}
option is enabled, multi-line commands are saved to the history with
embedded newlines rather than using semicolon separators where possible.
@item login_shell
The shell sets this option if it is started as a login shell
(@pxref{Invoking Bash}).
The value may not be changed.
@item mailwarn
If set, and a file that Bash is checking for mail has been
accessed since the last time it was checked, the message
@@ -3531,7 +3569,10 @@ The maximum amount of virtual memory available to the process.
@end table
If @var{limit} is given, it is the new value of the specified resource.
If @var{limit} is given, it is the new value of the specified resource;
the special @var{limit} values @code{hard}, @code{soft}, and
@code{unlimited} stand for the current hard limit, the current soft limit,
and no limit, respectively.
Otherwise, the current value of the soft limit for the specified resource
is printed, unless the @option{-H} option is supplied.
When setting new limits, if neither @option{-H} nor @option{-S} is supplied,
@@ -3541,9 +3582,8 @@ increments, except for @option{-t}, which is in seconds, @option{-p},
which is in units of 512-byte blocks, and @option{-n} and @option{-u}, which
are unscaled values.
The return status is zero unless an invalid option is supplied, a
non-numeric argument other than @code{unlimited} is supplied as a
@var{limit}, or an error occurs while setting a new limit.
The return status is zero unless an invalid option or argument is supplied,
or an error occurs while setting a new limit.
@item unalias
@btindex unalias
@@ -3591,6 +3631,7 @@ with a non-zero status, unless the command that fails is part of an
@code{until} or @code{while} loop, part of an @code{if} statement,
part of a @code{&&} or @code{||} list, or if the command's return
status is being inverted using @code{!}.
A trap on @code{ERR}, if set, is executed before the shell exits.
@item -f
Disable file name generation (globbing).
@@ -3657,6 +3698,9 @@ Same as @code{-n}.
@item noglob
Same as @code{-f}.
@item nolog
Currently ignored.
@item notify
Same as @code{-b}.
@@ -3927,11 +3971,10 @@ The value of @env{MACHTYPE}.
@end table
@item COMP_WORDS
An array variable consisting of the individual
words in the current command line.
This variable is available only in shell functions invoked by the
programmable completion facilities (@pxref{Programmable Completion}).
@item COLUMNS
Used by the @code{select} builtin command to determine the terminal width
when printing selection lists. Automatically set upon receipt of a
@code{SIGWINCH}.
@item COMP_CWORD
An index into @env{$@{COMP_WORDS@}} of the word containing the current
@@ -3954,6 +3997,12 @@ This variable is available only in shell functions and external
commands invoked by the
programmable completion facilities (@pxref{Programmable Completion}).
@item COMP_WORDS
An array variable consisting of the individual
words in the current command line.
This variable is available only in shell functions invoked by the
programmable completion facilities (@pxref{Programmable Completion}).
@item COMPREPLY
An array variable from which Bash reads the possible completions
generated by a shell function invoked by the programmable completion
@@ -3986,6 +4035,13 @@ A file name whose suffix matches one of the entries in
is excluded from the list of matched file names. A sample
value is @samp{.o:~}
@item FUNCNAME
The name of any currently-executing shell function.
This variable exists only when a shell function is executing.
Assignments to @env{FUNCNAME} have no effect and return an error status.
If @env{FUNCNAME} is unset, it loses its special properties, even if
it is subsequently reset.
@item GLOBIGNORE
A colon-separated list of patterns defining the set of filenames to
be ignored by filename expansion.
@@ -4019,13 +4075,6 @@ The history number, or index in the history list, of the current
command. If @env{HISTCMD} is unset, it loses its special properties,
even if it is subsequently reset.
@item FUNCNAME
The name of any currently-executing shell function.
This variable exists only when a shell function is executing.
Assignments to @env{FUNCNAME} have no effect and return an error status.
If @env{FUNCNAME} is unset, it loses its special properties, even if
it is subsequently reset.
@item HISTCONTROL
A value of @samp{ignorespace} means to not enter lines which
begin with a space or tab into the history list.
@@ -4038,6 +4087,18 @@ The second and subsequent lines of a multi-line compound command are
not tested, and are added to the history regardless of the value of
@env{HISTCONTROL}.
@item HISTFILE
The name of the file to which the command history is saved. The
default value is @file{~/.bash_history}.
@item HISTFILESIZE
The maximum number of lines contained in the history file. When this
variable is assigned a value, the history file is truncated, if
necessary, to contain no more than that number of lines.
The history file is also truncated to this size after
writing it when an interactive shell exits.
The default value is 500.
@item HISTIGNORE
A colon-separated list of patterns used to decide which command
lines should be saved on the history list. Each pattern is
@@ -4058,22 +4119,10 @@ pattern of @samp{[ ]*} is identical to @code{ignorespace}.
Combining these two patterns, separating them with a colon,
provides the functionality of @code{ignoreboth}.
@item HISTFILE
The name of the file to which the command history is saved. The
default value is @file{~/.bash_history}.
@item HISTSIZE
The maximum number of commands to remember on the history list.
The default value is 500.
@item HISTFILESIZE
The maximum number of lines contained in the history file. When this
variable is assigned a value, the history file is truncated, if
necessary, to contain no more than that number of lines.
The history file is also truncated to this size after
writing it when an interactive shell exits.
The default value is 500.
@item HOSTFILE
Contains the name of a file in the same format as @file{/etc/hosts} that
should be read when the shell needs to complete a hostname.
@@ -4133,19 +4182,14 @@ strings preceded by a @samp{$} (@pxref{Locale Translation}).
@item LC_NUMERIC
This variable determines the locale category used for number formatting.
@item LINENO
The line number in the script or shell function currently executing.
@item LINES
Used by the @code{select} builtin command to determine the column length
for printing selection lists. Automatically set upon receipt of a
@code{SIGWINCH}.
@item COLUMNS
Used by the @code{select} builtin command to determine the terminal width
when printing selection lists. Automatically set upon receipt of a
@code{SIGWINCH}.
@item LINENO
The line number in the script or shell function currently executing.
@item MACHTYPE
A string that fully describes the system type on which Bash
is executing, in the standard @sc{gnu} @var{cpu-company-system} format.
@@ -4174,6 +4218,18 @@ containing a list of exit status values from the processes
in the most-recently-executed foreground pipeline (which may
contain only a single command).
@item POSIXLY_CORRECT
If this variable is in the environment when @code{bash} starts, the shell
enters @sc{posix} mode (@pxref{Bash POSIX Mode}) before reading the
startup files, as if the @option{--posix} invocation option had been supplied.
If it is set while the shell is running, @code{bash} enables @sc{posix} mode,
as if the command
@example
@code{set -o posix}
@end example
@noindent
had been executed.
@item PPID
The process @sc{id} of the shell's parent process. This variable
is readonly.
@@ -4310,9 +4366,9 @@ This section describes features unique to Bash.
@section Invoking Bash
@example
bash [long-opt] [-ir] [-abefhkmnptuvxdBCDHP] [-o @var{option}] [@var{argument} @dots{}]
bash [long-opt] [-abefhkmnptuvxdBCDHP] [-o @var{option}] -c @var{string} [@var{argument} @dots{}]
bash [long-opt] -s [-abefhkmnptuvxdBCDHP] [-o @var{option}] [@var{argument} @dots{}]
bash [long-opt] [-ir] [-abefhkmnptuvxdBCDHP] [-o @var{option}] [-O @var{shopt_option}] [@var{argument} @dots{}]
bash [long-opt] [-abefhkmnptuvxdBCDHP] [-o @var{option}] [-O @var{shopt_option}] -c @var{string} [@var{argument} @dots{}]
bash [long-opt] -s [-abefhkmnptuvxdBCDHP] [-o @var{option}] [-O @var{shopt_option}] [@var{argument} @dots{}]
@end example
In addition to the single-character shell command-line options
@@ -4414,6 +4470,16 @@ are subject to language translation when the current locale
is not @code{C} or @code{POSIX} (@pxref{Locale Translation}).
This implies the @option{-n} option; no commands will be executed.
@item [-+]O [@var{shopt_option}]
@var{shopt_option} is one of the shell options accepted by the
@code{shopt} builtin (@pxref{Shell Builtin Commands}).
If @var{shopt_option} is present, @option{-O} sets the value of that option;
@option{+O} unsets it.
If @var{shopt_option} is not supplied, the names and values of the shell
options accepted by @code{shopt} are printed on the standard output.
If the invocation option is @option{+O}, the output is displayed in a format
that may be reused as input.
@item --
A @code{--} signals the end of options and disables further option
processing.
@@ -4421,6 +4487,10 @@ Any arguments after the @code{--} are treated as filenames and arguments.
@end table
@cindex login shell
A @emph{login} shell is one whose first character of argument zero is
@samp{-}, or one invoked with the @option{--login} option.
@cindex interactive shell
An @emph{interactive} shell is one started without non-option arguments,
unless @option{-s} is specified,
@@ -4930,7 +5000,7 @@ is a decimal number between 2 and 64 representing the arithmetic
base, and @var{n} is a number in that base. If @var{base}@code{#} is
omitted, then base 10 is used.
The digits greater than 9 are represented by the lowercase letters,
the uppercase letters, @samp{_}, and @samp{@@}, in that order.
the uppercase letters, @samp{@@}, and @samp{_}, in that order.
If @var{base} is less than or equal to 36, lowercase and uppercase
letters may be used interchangably to represent numbers between 10
and 35.
@@ -5065,7 +5135,7 @@ Referencing an array variable without a subscript is equivalent to
referencing element zero.
The @code{unset} builtin is used to destroy arrays.
@code{unset} @var{name[subscript]}
@code{unset} @var{name}[@var{subscript}]
destroys the array element at index @var{subscript}.
@code{unset} @var{name}, where @var{name} is an array, removes the
entire array. A subscript of @samp{*} or @samp{@@} also removes the
@@ -5230,6 +5300,8 @@ The time, in 24-hour HH:MM:SS format.
The time, in 12-hour HH:MM:SS format.
@item \@@
The time, in 12-hour am/pm format.
@item \A
The time, in 24-hour HH:MM format.
@item \u
The username of the current user.
@item \v
@@ -5462,6 +5534,10 @@ Alias expansion is always enabled, even in non-interactive shells.
When the @code{set} builtin is invoked without options, it does not display
shell function names and definitions.
@item
When the @code{set} builtin is invoked without options, it displays
variable values without quotes, unless they contain shell metacharacters,
even if the result contains nonprinting characters.
@end enumerate
There is other @sc{posix} 1003.2 behavior that Bash does not implement.
@@ -5585,9 +5661,11 @@ job 1 in the background, equivalent to @samp{bg %1}
The shell learns immediately whenever a job changes state.
Normally, Bash waits until it is about to print a prompt
before reporting changes in a job's status so as to not interrupt
any other output. If the
the @option{-b} option to the @code{set} builtin is enabled,
any other output.
If the @option{-b} option to the @code{set} builtin is enabled,
Bash reports such changes immediately (@pxref{The Set Builtin}).
Any trap on @code{SIGCHLD} is executed for each child process
that exits.
If an attempt to exit Bash is while jobs are stopped, the
shell prints a message warning that there are stopped jobs.
@@ -5867,18 +5945,9 @@ The file @file{configure.in} is used to create @code{configure}
by a program called Autoconf. You only need
@file{configure.in} if you want to change it or regenerate
@code{configure} using a newer version of Autoconf. If
you do this, make sure you are using Autoconf version 2.10 or
you do this, make sure you are using Autoconf version 2.50 or
newer.
If you need to change @file{configure.in} or regenerate
@code{configure}, you will need to create two files:
@file{_distribution} and @file{_patchlevel}. @file{_distribution}
should contain the major and minor version numbers of the Bash
distribution, for example @samp{2.01}. @file{_patchlevel} should
contain the patch level of the Bash distribution, @samp{0} for
example. The script @file{support/mkconffiles} has been provided
to automate the creation of these files.
You can remove the program binaries and object files from the
source code directory by typing @samp{make clean}. To also remove the
files that @code{configure} created (so you can compile Bash for
@@ -5947,7 +6016,9 @@ directories for other architectures.
By default, @samp{make install} will install into
@file{/usr/local/bin}, @file{/usr/local/man}, etc. You can
specify an installation prefix other than @file{/usr/local} by
giving @code{configure} the option @option{--prefix=@var{PATH}}.
giving @code{configure} the option @option{--prefix=@var{PATH}},
or by specifying a value for the @code{DESTDIR} @samp{make}
variable when running @samp{make install}.
You can specify separate installation prefixes for
architecture-specific files and architecture-independent files.
@@ -5960,13 +6031,13 @@ Documentation and other data files will still use the regular prefix.
@section Specifying the System Type
There may be some features @code{configure} can not figure out
automatically, but needs to determine by the type of host Bash
automatically, but need to determine by the type of host Bash
will run on. Usually @code{configure} can figure that
out, but if it prints a message saying it can not guess the host
type, give it the @option{--host=TYPE} option. @samp{TYPE} can
either be a short name for the system type, such as @samp{sun4},
or a canonical name with three fields: @samp{CPU-COMPANY-SYSTEM}
(e.g., @samp{sparc-sun-sunos4.1.2}).
(e.g., @samp{i386-unknown-freebsd4.2}).
See the file @file{support/config.sub} for the possible
values of each field.
@@ -6052,22 +6123,24 @@ Use the curses library instead of the termcap library. This should
be supplied if your system has an inadequate or incomplete termcap
database.
@item --with-glibc-malloc
Use the @sc{gnu} libc version of @code{malloc} in
@file{lib/malloc/gmalloc.c}. This is not the version of @code{malloc}
that appears in glibc version 2, but a modified version of the
@code{malloc} from glibc version 1. This is somewhat slower than the
default @code{malloc}, but wastes less space on a per-allocation
basis, and will return memory to the operating system under
certain circumstances.
@item --with-gnu-malloc
A synonym for @code{--with-bash-malloc}.
@item --with-installed-readline
@item --with-installed-readline[=@var{PREFIX}]
Define this to make Bash link with a locally-installed version of Readline
rather than the version in @file{lib/readline}. This works only with
Readline 4.1 and later versions.
Readline 4.2 and later versions. If @var{PREFIX} is @code{yes} or not
supplied, @code{configure} uses the values of the make variables
@code{includedir} and @code{libdir}, which are subdirectories of @code{prefix}
by default, to find the installed version of Readline if it is not in
the standard system include and library directories.
If @var{PREFIX} is @code{no}, Bash links with the version in
@file{lib/readline}.
If @var{PREFIX} is set to any other value, @code{configure} treats it as
a directory pathname and looks for
the installed version of Readline in subdirectories of that directory
(include files in @var{PREFIX}/@code{include} and the library in
@var{PREFIX}/@code{lib}).
@item --with-purify
Define this to use the Purify memory allocation checker from Rational
@@ -6082,6 +6155,11 @@ There are several @option{--enable-} options that alter how Bash is
compiled and linked, rather than changing run-time features.
@table @code
@item --enable-largefile
Enable support for @uref{http://www.sas.com/standards/large_file/x_open.20Mar96.html,
large files} if the operating system requires special compiler options
to build programs which can access large files.
@item --enable-profiling
This builds a Bash binary that produces profiling information to be
processed by @code{gprof} each time it is executed.
@@ -6533,7 +6611,8 @@ executed with the @code{.} or @code{source} builtins
@item
Bash includes the @code{shopt} builtin, for finer control of shell
optional capabilities (@pxref{Bash Builtins}).
optional capabilities (@pxref{Bash Builtins}), and allows these options
to be set and unset at shell invocation (@pxref{Invoking Bash}).
@item
Bash has much more optional behavior controllable with the @code{set}
@@ -6545,11 +6624,17 @@ is slightly different, as it implements the @sc{posix} algorithm,
which specifies the behavior based on the number of arguments.
@item
The @code{trap} builtin (@pxref{Bourne Shell Builtins})
allows a @code{DEBUG} pseudo-signal specification,
similar to @code{EXIT}. Commands specified with a @code{DEBUG} trap are
executed after every simple command. The @code{DEBUG} trap is not
inherited by shell functions.
The @code{trap} builtin (@pxref{Bourne Shell Builtins}) allows a
@code{DEBUG} pseudo-signal specification, similar to @code{EXIT}.
Commands specified with a @code{DEBUG} trap are executed after every
simple command.
The @code{DEBUG} trap is not inherited by shell functions.
The @code{trap} builtin (@pxref{Bourne Shell Builtins}) allows an
@code{ERR} pseudo-signal specification, similar to @code{EXIT} and @code{DEBUG}.
Commands specified with an @code{ERR} trap are executed after a simple
command fails, with a few exceptions.
The @code{ERR} trap is not inherited by shell functions.
@item
The Bash @code{type} builtin is more extensive and gives more information
+4 -3
View File
@@ -1,11 +1,12 @@
.\" This is a hack to force bash builtins into the whatis database
.\" and to get the list of builtins to come up with the man command.
.TH BASH_BUILTINS 1 "1996 Mar 20" GNU
.TH BASH_BUILTINS 1 "2001 October 29" "GNU Bash-2.05a"
.SH NAME
bash, :, ., alias, bg, bind, break, builtin, case, cd, command,
bash, :, ., [, alias, bg, bind, break, builtin, case, cd, command, compgen,
complete,
continue, declare, dirs, disown, echo, enable, eval, exec, exit,
export, fc, fg, for, getopts, hash, help, history, if, jobs, kill,
let, local, logout, popd, pushd, pwd, read, readonly, return, set,
let, local, logout, popd, printf, pushd, pwd, read, readonly, return, set,
shift, shopt, source, suspend, test, times, trap, type, typeset,
ulimit, umask, unalias, unset, until, wait, while \- bash built-in commands, see \fBbash\fR(1)
.SH BASH BUILTIN COMMANDS