commit bash-20100603 snapshot

This commit is contained in:
Chet Ramey
2011-12-12 22:00:02 -05:00
parent 6faad6254a
commit 220537f23e
65 changed files with 28747 additions and 18965 deletions
+30
View File
@@ -10045,3 +10045,33 @@ builtins/hash.def
- don't permit programs with slashes to be entered into the hash table
at all, even with the -p option. Inconsistency pointed out by
Jan Schampera <jan.schampera@web.de>
6/6
---
lib/readline/vi_mode.c
- finish restructuring rl_vi_domove and the functions that call it so
it works in callback mode, including numeric arguments. Requested
a long time ago by Bob Rossi
lib/readline/callback.c
- arrange to call appropriate callback when readline state indicates
RL_STATE_VIMOTION, so vi motion commands like `cw' and `d2w' are
handled in callback mode
lib/sh/wcswidth.c
- replacement wcswidth implementation
aclocal.m4
- add REPLACE_FUNCS(wcswidth) to BASH_CHECK_MULTIBYTE
execute_cmd.c
- fix select_query and print_index_and_element to compute correct
display width of select list elements in presence of multibyte
characters. Bug reported by Bernd Eggink <monoped@sudrala.de>
builtins/cd.def
- add posix-mandated -e option; currently ignored in most circumstances
doc/{bash.1,bashref.texi}
- document new `cd -e' option
+28
View File
@@ -10041,3 +10041,31 @@ doc/{bash.1,bashref.texi}
- document new %(datefmt)T printf format specifier and special
arguments
builtins/hash.def
- don't permit programs with slashes to be entered into the hash table
at all, even with the -p option. Inconsistency pointed out by
Jan Schampera <jan.schampera@web.de>
6/6
---
lib/readline/vi_mode.c
- finish restructuring rl_vi_domove and the functions that call it so
it works in callback mode, including numeric arguments. Requested
a long time ago by Bob Rossi
lib/readline/callback.c
- arrange to call appropriate callback when readline state indicates
RL_STATE_VIMOTION, so vi motion commands like `cw' and `d2w' are
handled in callback mode
lib/sh/wcswidth.c
- replacement wcswidth implementation
aclocal.m4
- add REPLACE_FUNCS(wcswidth) to BASH_CHECK_MULTIBYTE
execute_cmd.c
- fix select_query and print_index_and_element to compute correct
display width of select list elements in presence of multibyte
characters. Bug reported by Bernd Eggink <monoped@sudrala.de>
+3
View File
@@ -439,6 +439,7 @@ lib/sh/ufuncs.c f
lib/sh/unicode.c f
lib/sh/vprint.c f
lib/sh/wcsdup.c f
lib/sh/wcswidth.c f
lib/sh/winsize.c f
lib/sh/zcatfd.c f
lib/sh/zgetline.c f
@@ -517,6 +518,8 @@ po/sv.gmo f
po/sv.po f
po/tr.gmo f
po/tr.po f
po/uk.gmo f
po/uk.po f
po/vi.gmo f
po/vi.po f
po/zh_CN.gmo f
+3
View File
@@ -517,6 +517,8 @@ po/sv.gmo f
po/sv.po f
po/tr.gmo f
po/tr.po f
po/uk.gmo f
po/uk.po f
po/vi.gmo f
po/vi.po f
po/zh_CN.gmo f
@@ -942,6 +944,7 @@ tests/prec.right f
tests/precedence f
tests/printf.tests f
tests/printf.right f
tests/printf1.sub f
tests/printf2.sub f
tests/printf3.sub f
tests/quote.tests f
+2 -1
View File
@@ -214,7 +214,8 @@ SHLIB_SOURCE = ${SH_LIBSRC}/clktck.c ${SH_LIBSRC}/getcwd.c \
${SH_LIBSRC}/casemod.c ${SH_LIBSRC}/uconvert.c \
${SH_LIBSRC}/ufuncs.c ${SH_LIBSRC}/dprintf.c \
${SH_LIBSRC}/input_avail.c ${SH_LIBSRC}/mbscasecmp.c \
${SH_LIBSRC}/fnxform.c ${SH_LIBSRC}/unicode.c
${SH_LIBSRC}/fnxform.c ${SH_LIBSRC}/unicode.c \
${SH_LIBSRC}/wcswidth.c
SHLIB_LIB = -lsh
SHLIB_LIBNAME = libsh.a
+2 -2
View File
@@ -214,7 +214,7 @@ SHLIB_SOURCE = ${SH_LIBSRC}/clktck.c ${SH_LIBSRC}/getcwd.c \
${SH_LIBSRC}/casemod.c ${SH_LIBSRC}/uconvert.c \
${SH_LIBSRC}/ufuncs.c ${SH_LIBSRC}/dprintf.c \
${SH_LIBSRC}/input_avail.c ${SH_LIBSRC}/mbscasecmp.c \
${SH_LIBSRC}/fnxform.c
${SH_LIBSRC}/fnxform.c ${SH_LIBSRC}/unicode.c
SHLIB_LIB = -lsh
SHLIB_LIBNAME = libsh.a
@@ -1022,7 +1022,7 @@ subst.o: config.h bashtypes.h bashansi.h ${BASHINCDIR}/ansi_stdlib.h ${BASHINCDI
subst.o: shell.h syntax.h config.h bashjmp.h ${BASHINCDIR}/posixjmp.h command.h ${BASHINCDIR}/stdc.h error.h
subst.o: general.h xmalloc.h bashtypes.h variables.h arrayfunc.h conftypes.h array.h hashlib.h
subst.o: quit.h ${BASHINCDIR}/maxpath.h unwind_prot.h dispose_cmd.h
subst.o: make_cmd.h subst.h sig.h pathnames.h externs.h
subst.o: make_cmd.h subst.h sig.h pathnames.h externs.h parser.h
subst.o: flags.h jobs.h siglist.h execute_cmd.h ${BASHINCDIR}/filecntl.h trap.h pathexp.h
subst.o: mailcheck.h input.h $(DEFSRC)/getopt.h $(DEFSRC)/common.h
subst.o: bashline.h bashhist.h ${GLOB_LIBSRC}/strmatch.h
Vendored
+2
View File
@@ -1707,6 +1707,8 @@ AC_CHECK_FUNC(wcsdup, AC_DEFINE(HAVE_WCSDUP))
AC_CHECK_FUNC(wcwidth, AC_DEFINE(HAVE_WCWIDTH))
AC_CHECK_FUNC(wctype, AC_DEFINE(HAVE_WCTYPE))
AC_REPLACE_FUNCS(wcswidth)
dnl checks for both mbrtowc and mbstate_t
AC_FUNC_MBRTOWC
if test $ac_cv_func_mbrtowc = yes; then
Vendored
+5
View File
@@ -1695,16 +1695,21 @@ AC_CHECK_HEADERS(langinfo.h)
AC_CHECK_FUNC(mbrlen, AC_DEFINE(HAVE_MBRLEN))
AC_CHECK_FUNC(mbscasecmp, AC_DEFINE(HAVE_MBSCMP))
AC_CHECK_FUNC(mbscmp, AC_DEFINE(HAVE_MBSCMP))
AC_CHECK_FUNC(mbsnrtowcs, AC_DEFINE(HAVE_MBSNRTOWCS))
AC_CHECK_FUNC(mbsrtowcs, AC_DEFINE(HAVE_MBSRTOWCS))
AC_REPLACE_FUNCS(mbschr)
AC_CHECK_FUNC(wcrtomb, AC_DEFINE(HAVE_WCRTOMB))
AC_CHECK_FUNC(wcscoll, AC_DEFINE(HAVE_WCSCOLL))
AC_CHECK_FUNC(wcsdup, AC_DEFINE(HAVE_WCSDUP))
AC_CHECK_FUNC(wcswidth, AC_DEFINE(HAVE_WCSWIDTH))
AC_CHECK_FUNC(wcwidth, AC_DEFINE(HAVE_WCWIDTH))
AC_CHECK_FUNC(wctype, AC_DEFINE(HAVE_WCTYPE))
AC_REPLACE_FUNCS(wcswidth)
dnl checks for both mbrtowc and mbstate_t
AC_FUNC_MBRTOWC
if test $ac_cv_func_mbrtowc = yes; then
+110
View File
@@ -18314,6 +18314,116 @@ fi
for ac_func in wcswidth
do
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
$as_echo_n "checking for $ac_func... " >&6; }
if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
$as_echo_n "(cached) " >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
For example, HP-UX 11i <limits.h> declares gettimeofday. */
#define $ac_func innocuous_$ac_func
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func (); below.
Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
<limits.h> exists even on freestanding compilers. */
#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif
#undef $ac_func
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
char $ac_func ();
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined __stub_$ac_func || defined __stub___$ac_func
choke me
#endif
int
main ()
{
return $ac_func ();
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
(eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
$as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest$ac_exeext && {
test "$cross_compiling" = yes ||
$as_test_x conftest$ac_exeext
}; then
eval "$as_ac_var=yes"
else
$as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval 'as_val=${'$as_ac_var'}
$as_echo "$as_val"'`
{ $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_var'}
$as_echo "$as_val"'`
if test "x$as_val" = x""yes; then
cat >>confdefs.h <<_ACEOF
@%:@define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF
else
case " $LIB@&t@OBJS " in
*" $ac_func.$ac_objext "* ) ;;
*) LIB@&t@OBJS="$LIB@&t@OBJS $ac_func.$ac_objext"
;;
esac
fi
done
{ $as_echo "$as_me:$LINENO: checking whether mbrtowc and mbstate_t are properly declared" >&5
$as_echo_n "checking whether mbrtowc and mbstate_t are properly declared... " >&6; }
if test "${ac_cv_func_mbrtowc+set}" = set; then
+11 -11
View File
@@ -15,25 +15,25 @@
'configure.in'
],
{
'_LT_AC_TAGCONFIG' => 1,
'AM_PROG_F77_C_O' => 1,
'AC_INIT' => 1,
'_LT_AC_TAGCONFIG' => 1,
'm4_pattern_forbid' => 1,
'_AM_COND_IF' => 1,
'AC_INIT' => 1,
'AC_CANONICAL_TARGET' => 1,
'AC_SUBST' => 1,
'_AM_COND_IF' => 1,
'AC_CONFIG_LIBOBJ_DIR' => 1,
'AC_FC_SRCEXT' => 1,
'AC_SUBST' => 1,
'AC_CANONICAL_HOST' => 1,
'AC_FC_SRCEXT' => 1,
'AC_PROG_LIBTOOL' => 1,
'AM_INIT_AUTOMAKE' => 1,
'AC_CONFIG_SUBDIRS' => 1,
'AM_AUTOMAKE_VERSION' => 1,
'LT_CONFIG_LTDL_DIR' => 1,
'AC_REQUIRE_AUX_FILE' => 1,
'AC_CONFIG_LINKS' => 1,
'm4_sinclude' => 1,
'AC_REQUIRE_AUX_FILE' => 1,
'LT_SUPPORTED_TAG' => 1,
'm4_sinclude' => 1,
'AM_MAINTAINER_MODE' => 1,
'AM_GNU_GETTEXT_INTL_SUBDIR' => 1,
'_m4_warn' => 1,
@@ -49,13 +49,13 @@
'AC_CANONICAL_BUILD' => 1,
'AC_FC_FREEFORM' => 1,
'AH_OUTPUT' => 1,
'_AM_SUBST_NOTMAKE' => 1,
'AC_CONFIG_AUX_DIR' => 1,
'sinclude' => 1,
'm4_pattern_allow' => 1,
'_AM_SUBST_NOTMAKE' => 1,
'AM_PROG_CC_C_O' => 1,
'AC_CANONICAL_SYSTEM' => 1,
'm4_pattern_allow' => 1,
'sinclude' => 1,
'AM_CONDITIONAL' => 1,
'AC_CANONICAL_SYSTEM' => 1,
'AC_CONFIG_HEADERS' => 1,
'AC_DEFINE_TRACE_LITERAL' => 1,
'm4_include' => 1,
+55 -49
View File
@@ -171,7 +171,7 @@ m4trace:configure.in:51: -1- AC_SUBST_TRACE([host_os])
m4trace:configure.in:51: -1- m4_pattern_allow([^host_os$])
m4trace:configure.in:101: -2- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete.
You should run autoupdate.], [../../lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from...
aclocal.m4:1974: AM_PATH_LISPDIR is expanded from...
aclocal.m4:1976: AM_PATH_LISPDIR is expanded from...
configure.in:101: the top level])
m4trace:configure.in:101: -1- AC_SUBST([EMACS])
m4trace:configure.in:101: -1- AC_SUBST_TRACE([EMACS])
@@ -583,7 +583,7 @@ m4trace:configure.in:505: -1- _m4_warn([obsolete], [The macro `AC_TRY_RUN' is ob
You should run autoupdate.], [../../lib/autoconf/general.m4:2592: AC_TRY_RUN is expanded from...
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
aclocal.m4:1778: RL_LIB_READLINE_VERSION is expanded from...
aclocal.m4:1780: RL_LIB_READLINE_VERSION is expanded from...
configure.in:505: the top level])
m4trace:configure.in:505: -1- AC_DEFINE_TRACE_LITERAL([RL_READLINE_VERSION])
m4trace:configure.in:505: -1- m4_pattern_allow([^RL_READLINE_VERSION$])
@@ -774,8 +774,8 @@ m4trace:configure.in:651: -1- AC_SUBST_TRACE([MSGMERGE])
m4trace:configure.in:651: -1- m4_pattern_allow([^MSGMERGE$])
m4trace:configure.in:651: -1- _m4_warn([obsolete], [The macro `AC_OUTPUT_COMMANDS' is obsolete.
You should run autoupdate.], [../../lib/autoconf/status.m4:1022: AC_OUTPUT_COMMANDS is expanded from...
aclocal.m4:3679: AM_PO_SUBDIRS is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:3681: AM_PO_SUBDIRS is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([off_t])
m4trace:configure.in:651: -1- m4_pattern_allow([^off_t$])
@@ -835,9 +835,9 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2592: AC_TRY_RUN is
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2585: gt_INTDIV0 is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2587: gt_INTDIV0 is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([INTDIV0_RAISES_SIGFPE])
m4trace:configure.in:651: -1- m4_pattern_allow([^INTDIV0_RAISES_SIGFPE$])
@@ -848,10 +848,10 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2470: AC_TRY_COMPILE
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2687: jm_AC_HEADER_INTTYPES_H is expanded from...
aclocal.m4:3988: jm_AC_TYPE_UINTMAX_T is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2689: jm_AC_HEADER_INTTYPES_H is expanded from...
aclocal.m4:3990: jm_AC_TYPE_UINTMAX_T is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([HAVE_INTTYPES_H_WITH_UINTMAX])
m4trace:configure.in:651: -1- m4_pattern_allow([^HAVE_INTTYPES_H_WITH_UINTMAX$])
@@ -863,10 +863,10 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2470: AC_TRY_COMPILE
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:3958: jm_AC_HEADER_STDINT_H is expanded from...
aclocal.m4:3988: jm_AC_TYPE_UINTMAX_T is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:3960: jm_AC_HEADER_STDINT_H is expanded from...
aclocal.m4:3990: jm_AC_TYPE_UINTMAX_T is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([HAVE_STDINT_H_WITH_UINTMAX])
m4trace:configure.in:651: -1- m4_pattern_allow([^HAVE_STDINT_H_WITH_UINTMAX$])
@@ -878,10 +878,10 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2527: AC_TRY_LINK is
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:4015: jm_AC_TYPE_UNSIGNED_LONG_LONG is expanded from...
aclocal.m4:3988: jm_AC_TYPE_UINTMAX_T is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:4017: jm_AC_TYPE_UNSIGNED_LONG_LONG is expanded from...
aclocal.m4:3990: jm_AC_TYPE_UINTMAX_T is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([HAVE_UNSIGNED_LONG_LONG])
m4trace:configure.in:651: -1- m4_pattern_allow([^HAVE_UNSIGNED_LONG_LONG$])
@@ -901,9 +901,9 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2470: AC_TRY_COMPILE
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2660: gt_HEADER_INTTYPES_H is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2662: gt_HEADER_INTTYPES_H is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([HAVE_INTTYPES_H])
m4trace:configure.in:651: -1- m4_pattern_allow([^HAVE_INTTYPES_H$])
@@ -914,9 +914,9 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2470: AC_TRY_COMPILE
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2715: gt_INTTYPES_PRI is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2717: gt_INTTYPES_PRI is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([PRI_MACROS_BROKEN])
m4trace:configure.in:651: -1- m4_pattern_allow([^PRI_MACROS_BROKEN$])
@@ -993,20 +993,20 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2527: AC_TRY_LINK is
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2493: AM_ICONV_LINK is expanded from...
aclocal.m4:2548: AM_ICONV is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2495: AM_ICONV_LINK is expanded from...
aclocal.m4:2550: AM_ICONV is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete.
You should run autoupdate.], [../../lib/autoconf/general.m4:2527: AC_TRY_LINK is expanded from...
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2493: AM_ICONV_LINK is expanded from...
aclocal.m4:2548: AM_ICONV is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2495: AM_ICONV_LINK is expanded from...
aclocal.m4:2550: AM_ICONV is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([HAVE_ICONV])
m4trace:configure.in:651: -1- m4_pattern_allow([^HAVE_ICONV$])
@@ -1022,9 +1022,9 @@ m4trace:configure.in:651: -1- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' i
You should run autoupdate.], [../../lib/autoconf/general.m4:2470: AC_TRY_COMPILE is expanded from...
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
aclocal.m4:2548: AM_ICONV is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2550: AM_ICONV is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([ICONV_CONST])
m4trace:configure.in:651: -1- m4_pattern_allow([^ICONV_CONST$])
@@ -1035,9 +1035,9 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2527: AC_TRY_LINK is
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2012: AM_LANGINFO_CODESET is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2014: AM_LANGINFO_CODESET is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([HAVE_LANGINFO_CODESET])
m4trace:configure.in:651: -1- m4_pattern_allow([^HAVE_LANGINFO_CODESET$])
@@ -1048,9 +1048,9 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2527: AC_TRY_LINK is
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2782: AM_LC_MESSAGES is expanded from...
aclocal.m4:2371: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2784: AM_LC_MESSAGES is expanded from...
aclocal.m4:2373: AM_INTL_SUBDIR is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([HAVE_LC_MESSAGES])
m4trace:configure.in:651: -1- m4_pattern_allow([^HAVE_LC_MESSAGES$])
@@ -1067,21 +1067,21 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2527: AC_TRY_LINK is
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete.
You should run autoupdate.], [../../lib/autoconf/general.m4:2527: AC_TRY_LINK is expanded from...
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete.
You should run autoupdate.], [../../lib/autoconf/general.m4:2527: AC_TRY_LINK is expanded from...
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:2083: AM_GNU_GETTEXT is expanded from...
aclocal.m4:2085: AM_GNU_GETTEXT is expanded from...
configure.in:651: the top level])
m4trace:configure.in:651: -1- AC_DEFINE_TRACE_LITERAL([ENABLE_NLS])
m4trace:configure.in:651: -1- m4_pattern_allow([^ENABLE_NLS$])
@@ -1685,6 +1685,12 @@ m4trace:configure.in:805: -2- AC_DEFINE_TRACE_LITERAL([HAVE_WCWIDTH])
m4trace:configure.in:805: -2- m4_pattern_allow([^HAVE_WCWIDTH$])
m4trace:configure.in:805: -2- AC_DEFINE_TRACE_LITERAL([HAVE_WCTYPE])
m4trace:configure.in:805: -2- m4_pattern_allow([^HAVE_WCTYPE$])
m4trace:configure.in:805: -1- AC_LIBSOURCE([wcswidth.c])
m4trace:configure.in:805: -1- AH_OUTPUT([HAVE_WCSWIDTH], [/* Define to 1 if you have the `wcswidth\' function. */
#undef HAVE_WCSWIDTH])
m4trace:configure.in:805: -1- AC_SUBST([LIB@&t@OBJS], ["$LIB@&t@OBJS $ac_func.$ac_objext"])
m4trace:configure.in:805: -1- AC_SUBST_TRACE([LIB@&t@OBJS])
m4trace:configure.in:805: -1- m4_pattern_allow([^LIB@&t@OBJS$])
m4trace:configure.in:805: -1- AC_DEFINE_TRACE_LITERAL([HAVE_MBRTOWC])
m4trace:configure.in:805: -1- m4_pattern_allow([^HAVE_MBRTOWC$])
m4trace:configure.in:805: -1- AH_OUTPUT([HAVE_MBRTOWC], [/* Define to 1 if mbrtowc and mbstate_t are properly declared. */
@@ -2014,7 +2020,7 @@ m4trace:configure.in:886: -1- _m4_warn([obsolete], [The macro `AC_TRY_RUN' is ob
You should run autoupdate.], [../../lib/autoconf/general.m4:2592: AC_TRY_RUN is expanded from...
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
aclocal.m4:1892: BASH_FUNC_CTYPE_NONASCII is expanded from...
aclocal.m4:1894: BASH_FUNC_CTYPE_NONASCII is expanded from...
configure.in:886: the top level])
m4trace:configure.in:886: -1- AC_DEFINE_TRACE_LITERAL([CTYPE_NON_ASCII])
m4trace:configure.in:886: -1- m4_pattern_allow([^CTYPE_NON_ASCII$])
@@ -2301,7 +2307,7 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2592: AC_TRY_RUN is
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:4037: BASH_FUNC_SNPRINTF is expanded from...
aclocal.m4:4039: BASH_FUNC_SNPRINTF is expanded from...
configure.in:932: the top level])
m4trace:configure.in:932: -1- AC_DEFINE_TRACE_LITERAL([HAVE_SNPRINTF])
m4trace:configure.in:932: -1- m4_pattern_allow([^HAVE_SNPRINTF$])
@@ -2314,7 +2320,7 @@ You should run autoupdate.], [../../lib/autoconf/general.m4:2592: AC_TRY_RUN is
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:4065: BASH_FUNC_VSNPRINTF is expanded from...
aclocal.m4:4067: BASH_FUNC_VSNPRINTF is expanded from...
configure.in:933: the top level])
m4trace:configure.in:933: -1- AC_DEFINE_TRACE_LITERAL([HAVE_VSNPRINTF])
m4trace:configure.in:933: -1- m4_pattern_allow([^HAVE_VSNPRINTF$])
@@ -2398,7 +2404,7 @@ m4trace:configure.in:961: -1- _m4_warn([obsolete], [The macro `AC_TRY_RUN' is ob
You should run autoupdate.], [../../lib/autoconf/general.m4:2592: AC_TRY_RUN is expanded from...
../../lib/m4sugar/m4sh.m4:505: AS_IF is expanded from...
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
aclocal.m4:1936: BASH_CHECK_WCONTINUED is expanded from...
aclocal.m4:1938: BASH_CHECK_WCONTINUED is expanded from...
configure.in:961: the top level])
m4trace:configure.in:961: -1- AC_DEFINE_TRACE_LITERAL([WCONTINUED_BROKEN])
m4trace:configure.in:961: -1- m4_pattern_allow([^WCONTINUED_BROKEN$])
+13 -2
View File
@@ -67,9 +67,11 @@ int cdspelling = 0;
int cdable_vars;
static int eflag; /* file scope so bindpwd() can see it */
$BUILTIN cd
$FUNCTION cd_builtin
$SHORT_DOC cd [-L|-P] [dir]
$SHORT_DOC cd [-L|[-P [-e]]] [dir]
Change the shell working directory.
Change the current directory to DIR. The default DIR is the value of the
@@ -88,11 +90,14 @@ Options:
-L force symbolic links to be followed
-P use the physical directory structure without following symbolic
links
-e if the -P option is supplied, and the current working directory
cannot be determined successfully, exit with a non-zero status
The default is to follow symbolic links, as if `-L' were specified.
Exit Status:
Returns 0 if the directory is changed; non-zero otherwise.
Returns 0 if the directory is changed, and if $PWD is set successfully when
-P is used; non-zero otherwise.
$END
/* Just set $PWD, don't change OLDPWD. Used by `pwd -P' in posix mode. */
@@ -138,6 +143,8 @@ bindpwd (no_symlinks)
}
setpwd (dirname);
if (dirname == 0 && eflag)
r = EXECUTION_FAILURE;
if (dirname && dirname != the_current_working_directory)
free (dirname);
@@ -183,6 +190,7 @@ cd_builtin (list)
}
#endif /* RESTRICTED_SHELL */
eflag = 0;
no_symlinks = no_symbolic_links;
reset_internal_getopt ();
while ((opt = internal_getopt (list, "LP")) != -1)
@@ -195,6 +203,9 @@ cd_builtin (list)
case 'L':
no_symlinks = 0;
break;
case 'e':
eflag = 1;
break;
default:
builtin_usage ();
return (EXECUTION_FAILURE);
+11 -4
View File
@@ -1,7 +1,7 @@
This file is cd.def, from which is created cd.c. It implements the
builtins "cd" and "pwd" in Bash.
Copyright (C) 1987-2009 Free Software Foundation, Inc.
Copyright (C) 1987-2010 Free Software Foundation, Inc.
This file is part of GNU Bash, the Bourne Again SHell.
@@ -69,7 +69,7 @@ int cdable_vars;
$BUILTIN cd
$FUNCTION cd_builtin
$SHORT_DOC cd [-L|-P] [dir]
$SHORT_DOC cd [-L|[-P [-e]]] [dir]
Change the shell working directory.
Change the current directory to DIR. The default DIR is the value of the
@@ -88,11 +88,14 @@ Options:
-L force symbolic links to be followed
-P use the physical directory structure without following symbolic
links
-e if the -P option is supplied, and the current working directory
cannot be determined successfully, exit with a non-zero status
The default is to follow symbolic links, as if `-L' were specified.
Exit Status:
Returns 0 if the directory is changed; non-zero otherwise.
Returns 0 if the directory is changed, and if $PWD is set successfully when
-P is used; non-zero otherwise.
$END
/* Just set $PWD, don't change OLDPWD. Used by `pwd -P' in posix mode. */
@@ -173,7 +176,7 @@ cd_builtin (list)
WORD_LIST *list;
{
char *dirname, *cdpath, *path, *temp;
int path_index, no_symlinks, opt, lflag;
int path_index, no_symlinks, opt, lflag, eflag;
#if defined (RESTRICTED_SHELL)
if (restricted)
@@ -183,6 +186,7 @@ cd_builtin (list)
}
#endif /* RESTRICTED_SHELL */
eflag = 0;
no_symlinks = no_symbolic_links;
reset_internal_getopt ();
while ((opt = internal_getopt (list, "LP")) != -1)
@@ -195,6 +199,9 @@ cd_builtin (list)
case 'L':
no_symlinks = 0;
break;
case 'e':
eflag = 1;
break;
default:
builtin_usage ();
return (EXECUTION_FAILURE);
+3
View File
@@ -876,6 +876,9 @@
/* Define if you have the wctype function. */
#undef HAVE_WCTYPE
/* Define if you have the wcswidth function. */
#undef HAVE_WCSWIDTH
/* Define if you have the wcwidth function. */
#undef HAVE_WCWIDTH
+3
View File
@@ -555,6 +555,9 @@
/* Define if you have the eaccess function. */
#undef HAVE_EACCESS
/* Define if you have the faccessat function. */
#undef HAVE_FACCESSAT
/* Define if you have the fcntl function. */
#undef HAVE_FCNTL
Vendored
+110
View File
@@ -18314,6 +18314,116 @@ fi
for ac_func in wcswidth
do
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
$as_echo_n "checking for $ac_func... " >&6; }
if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
$as_echo_n "(cached) " >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
For example, HP-UX 11i <limits.h> declares gettimeofday. */
#define $ac_func innocuous_$ac_func
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func (); below.
Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
<limits.h> exists even on freestanding compilers. */
#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif
#undef $ac_func
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
char $ac_func ();
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined __stub_$ac_func || defined __stub___$ac_func
choke me
#endif
int
main ()
{
return $ac_func ();
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
(eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
$as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest$ac_exeext && {
test "$cross_compiling" = yes ||
$as_test_x conftest$ac_exeext
}; then
eval "$as_ac_var=yes"
else
$as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval 'as_val=${'$as_ac_var'}
$as_echo "$as_val"'`
{ $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_var'}
$as_echo "$as_val"'`
if test "x$as_val" = x""yes; then
cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF
else
case " $LIBOBJS " in
*" $ac_func.$ac_objext "* ) ;;
*) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
;;
esac
fi
done
{ $as_echo "$as_me:$LINENO: checking whether mbrtowc and mbstate_t are properly declared" >&5
$as_echo_n "checking whether mbrtowc and mbstate_t are properly declared... " >&6; }
if test "${ac_cv_func_mbrtowc+set}" = set; then
+1501 -1463
View File
File diff suppressed because it is too large Load Diff
+10 -2
View File
@@ -6737,7 +6737,7 @@ The return value is 0 unless the shell is not executing a subroutine
call or \fIexpr\fP does not correspond to a valid position in the
call stack.
.TP
\fBcd\fP [\fB\-L|-P\fP] [\fIdir\fP]
\fBcd\fP [\fB\-L\fP|[\fB\-P\fP [\fB\-e\fP]]] [\fIdir\fP]
Change the current directory to \fIdir\fP. The variable
.SM
.B HOME
@@ -6770,7 +6770,15 @@ option to the
.B set
builtin command); the
.B \-L
option forces symbolic links to be followed. An argument of
option forces symbolic links to be followed.
If the
.B \-e
option is supplied with
.BR \-P ,
and the current working directory cannot be successfully determined
after a successful directory change, \fBcd\fP will return an unsuccessful
status.
An argument of
.B \-
is equivalent to
.SM
+2 -2
View File
@@ -5,12 +5,12 @@
.\" Case Western Reserve University
.\" chet@po.cwru.edu
.\"
.\" Last Change: Sat May 29 20:59:17 EDT 2010
.\" Last Change: Sun May 30 17:03:08 EDT 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 May 29" "GNU Bash-4.1"
.TH BASH 1 "2010 May 30" "GNU Bash-4.1"
.\"
.\" There's some problem with having a `@'
.\" in a tagged paragraph with the BSD man macros.
+101 -19
View File
@@ -3,7 +3,7 @@
</HEAD>
<BODY><TABLE WIDTH=100%>
<TR>
<TH ALIGN=LEFT width=33%>BASH(1)<TH ALIGN=CENTER width=33%>2010 April 17<TH ALIGN=RIGHT width=33%>BASH(1)
<TH ALIGN=LEFT width=33%>BASH(1)<TH ALIGN=CENTER width=33%>2010 May 30<TH ALIGN=RIGHT width=33%>BASH(1)
</TR>
</TABLE>
<BR><A HREF="#index">Index</A>
@@ -751,6 +751,17 @@ under
below.
<P>
When the shell is in <I>posix mode</I>, <B>time</B>
may be followed by a newline. In this case, the shell displays the
total user and system time consumed by the shell and its children.
The
<FONT SIZE=-1><B>TIMEFORMAT</B>
</FONT>
variable may be used to specify the format of
the time information.
<P>
Each command in a pipeline is executed as a separate process (i.e., in a
subshell).
<A NAME="lbAN">&nbsp;</A>
@@ -1423,6 +1434,16 @@ the eight-bit character whose value is the octal value <I>nnn</I>
<DD>
the eight-bit character whose value is the hexadecimal value <I>HH</I>
(one or two hex digits)
<DT><B>\u</B><I>HHHH</I>
<DD>
the Unicode (ISO/IEC 10646) character whose value is the hexadecimal value
<I>HHHH</I> (one to four hex digits)
<DT><B>\U</B><I>HHHHHHHH</I>
<DD>
the Unicode (ISO/IEC 10646) character whose value is the hexadecimal value
<I>HHHHHHHH</I> (one to eight hex digits)
<DT><B>\c</B><I>x</I>
<DD>
@@ -2413,6 +2434,12 @@ is excluded from the list of matched filenames.
A sample value is
<TT>&quot;.o:~&quot;</TT>.
<DT><B>FUNCNEST</B>
<DD>
If set to a numeric value greater than 0, defines a maximum function
nesting level. Function invocations that exceed this nesting level
will cause the current command to abort.
<DT><B>GLOBIGNORE</B>
<DD>
@@ -4878,6 +4905,12 @@ builtin command. Ordinarily, variables and their values
are shared between the function and its caller.
<P>
The <B>FUNCNEST</B> variable, if set to a numeric value greater
than 0, defines a maximum function nesting level. Function
invocations that exceed the limit cause the entire command to
abort.
<P>
If the builtin command
<B>return</B>
@@ -5182,7 +5215,7 @@ and <I>file1</I> does not.
<DT><B>-o </B><I>optname</I>
<DD>
True if shell option
True if the shell option
<I>optname</I>
is enabled.
@@ -5193,6 +5226,13 @@ option to the
<B>set</B>
builtin below.
<DT><B>-v </B><I>varname</I>
<DD>
True if the shell variable
<I>varname</I>
is set (has been assigned a value).
<DT><B>-z </B><I>string</I>
<DD>
@@ -9068,9 +9108,9 @@ must be >= 1. If
is greater than the number of enclosing loops, the last enclosing loop
(the ``top-level'' loop) is resumed.
The return value is 0 unless <I>n</I> is not greater than or equal to 1.
<DT><B>declare</B> [<B>-aAfFilrtux</B>] [<B>-p</B>] [<I>name</I>[=<I>value</I>] ...]<DD>
<DT><B>declare</B> [<B>-aAfFgilrtux</B>] [<B>-p</B>] [<I>name</I>[=<I>value</I>] ...]<DD>
<DT><B>typeset</B> [<B>-aAfFilrtux</B>] [<B>-p</B>] [<I>name</I>[=<I>value</I>] ...]<DD>
<DT><B>typeset</B> [<B>-aAfFgilrtux</B>] [<B>-p</B>] [<I>name</I>[=<I>value</I>] ...]<DD>
Declare variables and/or give them attributes.
If no <I>name</I>s are given then display the values of variables.
@@ -9106,6 +9146,12 @@ are displayed as well. The
option implies
<B>-f</B>.
The
<B>-g</B>
option forces variables to be created or modified at the global scope,
even when <B>declare</B> is executed in a shell function.
It is ignored in all other cases.
The following options can
be used to restrict output to variables with the specified attribute or
to give variables attributes:
@@ -9175,13 +9221,13 @@ turns off the attribute instead,
with the exceptions that <B>+a</B>
may not be used to destroy an array variable and <B>+r</B> will not
remove the readonly attribute.
When used in a function,
makes each
When used in a function, makes each
<I>name</I> local, as with the
<B>local</B>
command.
If a variable name is followed by =<I>value</I>, the value of
command,
unless the <B>-gP option is supplied,
If a variable name is followed by =</B><I>value</I>, the value of
the variable is set to <I>value</I>.
The return value is 0 unless an invalid option is encountered,
an attempt is made to define a function using
@@ -9373,6 +9419,16 @@ the eight-bit character whose value is the octal value <I>nnn</I>
<DD>
the eight-bit character whose value is the hexadecimal value <I>HH</I>
(one or two hex digits)
<DT><B>\u</B><I>HHHH</I>
<DD>
the Unicode (ISO/IEC 10646) character whose value is the hexadecimal value
<I>HHHH</I> (one to four hex digits)
<DT><B>\U</B><I>HHHHHHHH</I>
<DD>
the Unicode (ISO/IEC 10646) character whose value is the hexadecimal value
<I>HHHHHHHH</I> (one to eight hex digits)
</DL></DL>
@@ -10242,7 +10298,8 @@ is specified without
the default quantum is 5000.
When <I>callback</I> is evaluated, it is supplied the index of the next
array element to be assigned as an additional argument.
array element to be assigned and the line to be assigned to that element
as additional arguments.
<I>callback</I> is evaluated after the line is read but before the
array element is assigned.
<P>
@@ -10316,32 +10373,57 @@ directory change fails.
<DT><B>printf</B> [<B>-v</B> <I>var</I>] <I>format</I> [<I>arguments</I>]<DD>
Write the formatted <I>arguments</I> to the standard output under the
control of the <I>format</I>.
The <B>-v</B> option causes the output to be assigned to the variable
<I>var</I> rather than being printed to the standard output.
<P>
The <I>format</I> is a character string which contains three types of objects:
plain characters, which are simply copied to standard output, character
escape sequences, which are converted and copied to the standard output, and
format specifications, each of which causes printing of the next successive
<I>argument</I>.
In addition to the standard <I>printf</I>(1) formats, <B>%b</B> causes
In addition to the standard <I>printf</I>(1) format specifications,
<B>printf</B> interprets the following extensions:
<DL COMPACT><DT><DD>
<DL COMPACT>
<DT><B>%b</B>
<DD>
causes
<B>printf</B> to expand backslash escape sequences in the corresponding
<I>argument</I> (except that <B>\c</B> terminates output, backslashes in
<B>\aq</B>, <B>\&quot;</B>, and <B>\?</B> are not removed, and octal escapes
beginning with <B>\0</B> may contain up to four digits),
and <B>%q</B> causes <B>printf</B> to output the corresponding
beginning with <B>\0</B> may contain up to four digits).
<DT><B>%q</B>
<DD>
causes <B>printf</B> to output the corresponding
<I>argument</I> in a format that can be reused as shell input.
<DT><B>%(</B><I>datefmt</I>)T
<DD>
causes <B>printf</B> to output the date-time string resulting from using
<I>datefmt</I> as a format string for <I>strftime</I>(3). The corresponding
<I>argument</I> is an integer representing the number of seconds since the
epoch. Two special argument values may be used: -1 represents the current
time, and -2 represents the time the shell was invoked.
</DL>
<P>
Arguments to non-string format specifiers are treated as C constants,
except that a leading plus or minus sign is allowed, and if the leading
character is a single or double quote, the value is the ASCII value of
the following character.
<P>
The <B>-v</B> option causes the output to be assigned to the variable
<I>var</I> rather than being printed to the standard output.
<P>
The <I>format</I> is reused as necessary to consume all of the <I>arguments</I>.
If the <I>format</I> requires more <I>arguments</I> than are supplied, the
extra format specifications behave as if a zero value or null string, as
appropriate, had been supplied. The return value is zero on success,
non-zero on failure.
appropriate, had been supplied.
The return value is zero on success, non-zero on failure.
</DL>
<DT><B>pushd</B> [<B>-n</B>] [+<I>n</I>] [-<I>n</I>]<DD>
<DT><B>pushd</B> [<B>-n</B>] [<I>dir</I>]<DD>
@@ -12516,7 +12598,7 @@ There may be only one active coprocess at a time.
<HR>
<TABLE WIDTH=100%>
<TR>
<TH ALIGN=LEFT width=33%>GNU Bash-4.1<TH ALIGN=CENTER width=33%>2010 April 17<TH ALIGN=RIGHT width=33%>BASH(1)
<TH ALIGN=LEFT width=33%>GNU Bash-4.1<TH ALIGN=CENTER width=33%>2010 May 30<TH ALIGN=RIGHT width=33%>BASH(1)
</TR>
</TABLE>
<HR>
@@ -12622,6 +12704,6 @@ There may be only one active coprocess at a time.
</DL>
<HR>
This document was created by man2html from bash.1.<BR>
Time: 20 May 2010 16:33:15 EDT
Time: 01 June 2010 11:58:46 EDT
</BODY>
</HTML>
BIN
View File
Binary file not shown.
+5832 -5788
View File
File diff suppressed because it is too large Load Diff
+115 -112
View File
@@ -40,195 +40,198 @@
@xrdef{Comments-snt}{Section@tie 3.1.3}
@xrdef{Shell Commands-title}{Shell Commands}
@xrdef{Shell Commands-snt}{Section@tie 3.2}
@xrdef{Simple Commands-title}{Simple Commands}
@xrdef{Simple Commands-snt}{Section@tie 3.2.1}
@xrdef{Locale Translation-pg}{7}
@xrdef{Comments-pg}{7}
@xrdef{Shell Commands-pg}{7}
@xrdef{Simple Commands-title}{Simple Commands}
@xrdef{Simple Commands-snt}{Section@tie 3.2.1}
@xrdef{Pipelines-title}{Pipelines}
@xrdef{Pipelines-snt}{Section@tie 3.2.2}
@xrdef{Lists-title}{Lists of Commands}
@xrdef{Lists-snt}{Section@tie 3.2.3}
@xrdef{Shell Commands-pg}{8}
@xrdef{Simple Commands-pg}{8}
@xrdef{Pipelines-pg}{8}
@xrdef{Lists-pg}{8}
@xrdef{Lists-title}{Lists of Commands}
@xrdef{Lists-snt}{Section@tie 3.2.3}
@xrdef{Compound Commands-title}{Compound Commands}
@xrdef{Compound Commands-snt}{Section@tie 3.2.4}
@xrdef{Looping Constructs-title}{Looping Constructs}
@xrdef{Looping Constructs-snt}{Section@tie 3.2.4.1}
@xrdef{Lists-pg}{9}
@xrdef{Compound Commands-pg}{9}
@xrdef{Looping Constructs-pg}{9}
@xrdef{Conditional Constructs-title}{Conditional Constructs}
@xrdef{Conditional Constructs-snt}{Section@tie 3.2.4.2}
@xrdef{Looping Constructs-pg}{10}
@xrdef{Conditional Constructs-pg}{10}
@xrdef{Command Grouping-title}{Grouping Commands}
@xrdef{Command Grouping-snt}{Section@tie 3.2.4.3}
@xrdef{Command Grouping-pg}{13}
@xrdef{Coprocesses-title}{Coprocesses}
@xrdef{Coprocesses-snt}{Section@tie 3.2.5}
@xrdef{Command Grouping-pg}{13}
@xrdef{GNU Parallel-title}{GNU Parallel}
@xrdef{GNU Parallel-snt}{Section@tie 3.2.6}
@xrdef{Coprocesses-pg}{14}
@xrdef{GNU Parallel-pg}{14}
@xrdef{Shell Functions-title}{Shell Functions}
@xrdef{Shell Functions-snt}{Section@tie 3.3}
@xrdef{Coprocesses-pg}{14}
@xrdef{Shell Functions-pg}{14}
@xrdef{Shell Functions-pg}{15}
@xrdef{Shell Parameters-title}{Shell Parameters}
@xrdef{Shell Parameters-snt}{Section@tie 3.4}
@xrdef{Shell Parameters-pg}{15}
@xrdef{Positional Parameters-title}{Positional Parameters}
@xrdef{Positional Parameters-snt}{Section@tie 3.4.1}
@xrdef{Special Parameters-title}{Special Parameters}
@xrdef{Special Parameters-snt}{Section@tie 3.4.2}
@xrdef{Positional Parameters-pg}{16}
@xrdef{Special Parameters-pg}{16}
@xrdef{Shell Parameters-pg}{17}
@xrdef{Positional Parameters-pg}{17}
@xrdef{Shell Expansions-title}{Shell Expansions}
@xrdef{Shell Expansions-snt}{Section@tie 3.5}
@xrdef{Shell Expansions-pg}{17}
@xrdef{Special Parameters-pg}{18}
@xrdef{Shell Expansions-pg}{18}
@xrdef{Brace Expansion-title}{Brace Expansion}
@xrdef{Brace Expansion-snt}{Section@tie 3.5.1}
@xrdef{Brace Expansion-pg}{19}
@xrdef{Tilde Expansion-title}{Tilde Expansion}
@xrdef{Tilde Expansion-snt}{Section@tie 3.5.2}
@xrdef{Brace Expansion-pg}{18}
@xrdef{Tilde Expansion-pg}{20}
@xrdef{Shell Parameter Expansion-title}{Shell Parameter Expansion}
@xrdef{Shell Parameter Expansion-snt}{Section@tie 3.5.3}
@xrdef{Tilde Expansion-pg}{19}
@xrdef{Shell Parameter Expansion-pg}{19}
@xrdef{Shell Parameter Expansion-pg}{21}
@xrdef{Command Substitution-title}{Command Substitution}
@xrdef{Command Substitution-snt}{Section@tie 3.5.4}
@xrdef{Command Substitution-pg}{22}
@xrdef{Arithmetic Expansion-title}{Arithmetic Expansion}
@xrdef{Arithmetic Expansion-snt}{Section@tie 3.5.5}
@xrdef{Process Substitution-title}{Process Substitution}
@xrdef{Process Substitution-snt}{Section@tie 3.5.6}
@xrdef{Word Splitting-title}{Word Splitting}
@xrdef{Word Splitting-snt}{Section@tie 3.5.7}
@xrdef{Arithmetic Expansion-pg}{23}
@xrdef{Process Substitution-pg}{23}
@xrdef{Word Splitting-pg}{23}
@xrdef{Command Substitution-pg}{24}
@xrdef{Arithmetic Expansion-pg}{24}
@xrdef{Process Substitution-pg}{24}
@xrdef{Filename Expansion-title}{Filename Expansion}
@xrdef{Filename Expansion-snt}{Section@tie 3.5.8}
@xrdef{Pattern Matching-title}{Pattern Matching}
@xrdef{Pattern Matching-snt}{Section@tie 3.5.8.1}
@xrdef{Filename Expansion-pg}{24}
@xrdef{Pattern Matching-pg}{24}
@xrdef{Word Splitting-pg}{25}
@xrdef{Filename Expansion-pg}{25}
@xrdef{Pattern Matching-pg}{26}
@xrdef{Quote Removal-title}{Quote Removal}
@xrdef{Quote Removal-snt}{Section@tie 3.5.9}
@xrdef{Redirections-title}{Redirections}
@xrdef{Redirections-snt}{Section@tie 3.6}
@xrdef{Quote Removal-pg}{25}
@xrdef{Redirections-pg}{26}
@xrdef{Quote Removal-pg}{27}
@xrdef{Redirections-pg}{27}
@xrdef{Executing Commands-title}{Executing Commands}
@xrdef{Executing Commands-snt}{Section@tie 3.7}
@xrdef{Simple Command Expansion-title}{Simple Command Expansion}
@xrdef{Simple Command Expansion-snt}{Section@tie 3.7.1}
@xrdef{Executing Commands-pg}{29}
@xrdef{Simple Command Expansion-pg}{29}
@xrdef{Executing Commands-pg}{30}
@xrdef{Simple Command Expansion-pg}{30}
@xrdef{Command Search and Execution-title}{Command Search and Execution}
@xrdef{Command Search and Execution-snt}{Section@tie 3.7.2}
@xrdef{Command Search and Execution-pg}{31}
@xrdef{Command Execution Environment-title}{Command Execution Environment}
@xrdef{Command Execution Environment-snt}{Section@tie 3.7.3}
@xrdef{Command Search and Execution-pg}{30}
@xrdef{Command Execution Environment-pg}{30}
@xrdef{Command Execution Environment-pg}{32}
@xrdef{Environment-title}{Environment}
@xrdef{Environment-snt}{Section@tie 3.7.4}
@xrdef{Environment-pg}{31}
@xrdef{Exit Status-title}{Exit Status}
@xrdef{Exit Status-snt}{Section@tie 3.7.5}
@xrdef{Environment-pg}{33}
@xrdef{Exit Status-pg}{33}
@xrdef{Signals-title}{Signals}
@xrdef{Signals-snt}{Section@tie 3.7.6}
@xrdef{Exit Status-pg}{32}
@xrdef{Signals-pg}{32}
@xrdef{Shell Scripts-title}{Shell Scripts}
@xrdef{Shell Scripts-snt}{Section@tie 3.8}
@xrdef{Shell Scripts-pg}{33}
@xrdef{Signals-pg}{34}
@xrdef{Shell Scripts-pg}{34}
@xrdef{Shell Builtin Commands-title}{Shell Builtin Commands}
@xrdef{Shell Builtin Commands-snt}{Chapter@tie 4}
@xrdef{Bourne Shell Builtins-title}{Bourne Shell Builtins}
@xrdef{Bourne Shell Builtins-snt}{Section@tie 4.1}
@xrdef{Shell Builtin Commands-pg}{35}
@xrdef{Bourne Shell Builtins-pg}{35}
@xrdef{Shell Builtin Commands-pg}{37}
@xrdef{Bourne Shell Builtins-pg}{37}
@xrdef{Bash Builtins-title}{Bash Builtin Commands}
@xrdef{Bash Builtins-snt}{Section@tie 4.2}
@xrdef{Bash Builtins-pg}{41}
@xrdef{Bash Builtins-pg}{43}
@xrdef{Modifying Shell Behavior-title}{Modifying Shell Behavior}
@xrdef{Modifying Shell Behavior-snt}{Section@tie 4.3}
@xrdef{The Set Builtin-title}{The Set Builtin}
@xrdef{The Set Builtin-snt}{Section@tie 4.3.1}
@xrdef{Modifying Shell Behavior-pg}{51}
@xrdef{The Set Builtin-pg}{51}
@xrdef{Modifying Shell Behavior-pg}{53}
@xrdef{The Set Builtin-pg}{53}
@xrdef{The Shopt Builtin-title}{The Shopt Builtin}
@xrdef{The Shopt Builtin-snt}{Section@tie 4.3.2}
@xrdef{The Shopt Builtin-pg}{55}
@xrdef{The Shopt Builtin-pg}{57}
@xrdef{Special Builtins-title}{Special Builtins}
@xrdef{Special Builtins-snt}{Section@tie 4.4}
@xrdef{Special Builtins-pg}{59}
@xrdef{Special Builtins-pg}{62}
@xrdef{Shell Variables-title}{Shell Variables}
@xrdef{Shell Variables-snt}{Chapter@tie 5}
@xrdef{Bourne Shell Variables-title}{Bourne Shell Variables}
@xrdef{Bourne Shell Variables-snt}{Section@tie 5.1}
@xrdef{Bash Variables-title}{Bash Variables}
@xrdef{Bash Variables-snt}{Section@tie 5.2}
@xrdef{Shell Variables-pg}{61}
@xrdef{Bourne Shell Variables-pg}{61}
@xrdef{Bash Variables-pg}{61}
@xrdef{Shell Variables-pg}{63}
@xrdef{Bourne Shell Variables-pg}{63}
@xrdef{Bash Variables-pg}{63}
@xrdef{Bash Features-title}{Bash Features}
@xrdef{Bash Features-snt}{Chapter@tie 6}
@xrdef{Invoking Bash-title}{Invoking Bash}
@xrdef{Invoking Bash-snt}{Section@tie 6.1}
@xrdef{Bash Features-pg}{71}
@xrdef{Invoking Bash-pg}{71}
@xrdef{Bash Features-pg}{73}
@xrdef{Invoking Bash-pg}{73}
@xrdef{Bash Startup Files-title}{Bash Startup Files}
@xrdef{Bash Startup Files-snt}{Section@tie 6.2}
@xrdef{Bash Startup Files-pg}{73}
@xrdef{Bash Startup Files-pg}{75}
@xrdef{Interactive Shells-title}{Interactive Shells}
@xrdef{Interactive Shells-snt}{Section@tie 6.3}
@xrdef{What is an Interactive Shell?-title}{What is an Interactive Shell?}
@xrdef{What is an Interactive Shell?-snt}{Section@tie 6.3.1}
@xrdef{Interactive Shells-pg}{74}
@xrdef{Interactive Shells-pg}{76}
@xrdef{Is this Shell Interactive?-title}{Is this Shell Interactive?}
@xrdef{Is this Shell Interactive?-snt}{Section@tie 6.3.2}
@xrdef{Interactive Shell Behavior-title}{Interactive Shell Behavior}
@xrdef{Interactive Shell Behavior-snt}{Section@tie 6.3.3}
@xrdef{What is an Interactive Shell?-pg}{75}
@xrdef{Is this Shell Interactive?-pg}{75}
@xrdef{Interactive Shell Behavior-pg}{75}
@xrdef{What is an Interactive Shell?-pg}{77}
@xrdef{Is this Shell Interactive?-pg}{77}
@xrdef{Interactive Shell Behavior-pg}{77}
@xrdef{Bash Conditional Expressions-title}{Bash Conditional Expressions}
@xrdef{Bash Conditional Expressions-snt}{Section@tie 6.4}
@xrdef{Bash Conditional Expressions-pg}{76}
@xrdef{Bash Conditional Expressions-pg}{78}
@xrdef{Shell Arithmetic-title}{Shell Arithmetic}
@xrdef{Shell Arithmetic-snt}{Section@tie 6.5}
@xrdef{Shell Arithmetic-pg}{78}
@xrdef{Shell Arithmetic-pg}{80}
@xrdef{Aliases-title}{Aliases}
@xrdef{Aliases-snt}{Section@tie 6.6}
@xrdef{Aliases-pg}{79}
@xrdef{Aliases-pg}{81}
@xrdef{Arrays-title}{Arrays}
@xrdef{Arrays-snt}{Section@tie 6.7}
@xrdef{Arrays-pg}{80}
@xrdef{Arrays-pg}{82}
@xrdef{The Directory Stack-title}{The Directory Stack}
@xrdef{The Directory Stack-snt}{Section@tie 6.8}
@xrdef{Directory Stack Builtins-title}{Directory Stack Builtins}
@xrdef{Directory Stack Builtins-snt}{Section@tie 6.8.1}
@xrdef{The Directory Stack-pg}{81}
@xrdef{Directory Stack Builtins-pg}{81}
@xrdef{The Directory Stack-pg}{83}
@xrdef{Directory Stack Builtins-pg}{83}
@xrdef{Printing a Prompt-title}{Controlling the Prompt}
@xrdef{Printing a Prompt-snt}{Section@tie 6.9}
@xrdef{Printing a Prompt-pg}{82}
@xrdef{Printing a Prompt-pg}{84}
@xrdef{The Restricted Shell-title}{The Restricted Shell}
@xrdef{The Restricted Shell-snt}{Section@tie 6.10}
@xrdef{Bash POSIX Mode-title}{Bash POSIX Mode}
@xrdef{Bash POSIX Mode-snt}{Section@tie 6.11}
@xrdef{The Restricted Shell-pg}{84}
@xrdef{Bash POSIX Mode-pg}{84}
@xrdef{The Restricted Shell-pg}{86}
@xrdef{Bash POSIX Mode-pg}{86}
@xrdef{Job Control-title}{Job Control}
@xrdef{Job Control-snt}{Chapter@tie 7}
@xrdef{Job Control Basics-title}{Job Control Basics}
@xrdef{Job Control Basics-snt}{Section@tie 7.1}
@xrdef{Job Control-pg}{89}
@xrdef{Job Control Basics-pg}{89}
@xrdef{Job Control-pg}{91}
@xrdef{Job Control Basics-pg}{91}
@xrdef{Job Control Builtins-title}{Job Control Builtins}
@xrdef{Job Control Builtins-snt}{Section@tie 7.2}
@xrdef{Job Control Builtins-pg}{90}
@xrdef{Job Control Builtins-pg}{92}
@xrdef{Job Control Variables-title}{Job Control Variables}
@xrdef{Job Control Variables-snt}{Section@tie 7.3}
@xrdef{Job Control Variables-pg}{92}
@xrdef{Job Control Variables-pg}{94}
@xrdef{Command Line Editing-title}{Command Line Editing}
@xrdef{Command Line Editing-snt}{Chapter@tie 8}
@xrdef{Introduction and Notation-title}{Introduction to Line Editing}
@@ -237,142 +240,142 @@
@xrdef{Readline Interaction-snt}{Section@tie 8.2}
@xrdef{Readline Bare Essentials-title}{Readline Bare Essentials}
@xrdef{Readline Bare Essentials-snt}{Section@tie 8.2.1}
@xrdef{Command Line Editing-pg}{93}
@xrdef{Introduction and Notation-pg}{93}
@xrdef{Readline Interaction-pg}{93}
@xrdef{Command Line Editing-pg}{95}
@xrdef{Introduction and Notation-pg}{95}
@xrdef{Readline Interaction-pg}{95}
@xrdef{Readline Movement Commands-title}{Readline Movement Commands}
@xrdef{Readline Movement Commands-snt}{Section@tie 8.2.2}
@xrdef{Readline Killing Commands-title}{Readline Killing Commands}
@xrdef{Readline Killing Commands-snt}{Section@tie 8.2.3}
@xrdef{Readline Bare Essentials-pg}{94}
@xrdef{Readline Movement Commands-pg}{94}
@xrdef{Readline Bare Essentials-pg}{96}
@xrdef{Readline Movement Commands-pg}{96}
@xrdef{Readline Arguments-title}{Readline Arguments}
@xrdef{Readline Arguments-snt}{Section@tie 8.2.4}
@xrdef{Searching-title}{Searching for Commands in the History}
@xrdef{Searching-snt}{Section@tie 8.2.5}
@xrdef{Readline Killing Commands-pg}{95}
@xrdef{Readline Arguments-pg}{95}
@xrdef{Searching-pg}{95}
@xrdef{Readline Killing Commands-pg}{97}
@xrdef{Readline Arguments-pg}{97}
@xrdef{Searching-pg}{97}
@xrdef{Readline Init File-title}{Readline Init File}
@xrdef{Readline Init File-snt}{Section@tie 8.3}
@xrdef{Readline Init File Syntax-title}{Readline Init File Syntax}
@xrdef{Readline Init File Syntax-snt}{Section@tie 8.3.1}
@xrdef{Readline Init File-pg}{96}
@xrdef{Readline Init File Syntax-pg}{96}
@xrdef{Readline Init File-pg}{98}
@xrdef{Readline Init File Syntax-pg}{98}
@xrdef{Conditional Init Constructs-title}{Conditional Init Constructs}
@xrdef{Conditional Init Constructs-snt}{Section@tie 8.3.2}
@xrdef{Conditional Init Constructs-pg}{102}
@xrdef{Conditional Init Constructs-pg}{104}
@xrdef{Sample Init File-title}{Sample Init File}
@xrdef{Sample Init File-snt}{Section@tie 8.3.3}
@xrdef{Sample Init File-pg}{103}
@xrdef{Sample Init File-pg}{105}
@xrdef{Bindable Readline Commands-title}{Bindable Readline Commands}
@xrdef{Bindable Readline Commands-snt}{Section@tie 8.4}
@xrdef{Commands For Moving-title}{Commands For Moving}
@xrdef{Commands For Moving-snt}{Section@tie 8.4.1}
@xrdef{Commands For History-title}{Commands For Manipulating The History}
@xrdef{Commands For History-snt}{Section@tie 8.4.2}
@xrdef{Bindable Readline Commands-pg}{106}
@xrdef{Commands For Moving-pg}{106}
@xrdef{Commands For History-pg}{107}
@xrdef{Bindable Readline Commands-pg}{108}
@xrdef{Commands For Moving-pg}{108}
@xrdef{Commands For History-pg}{109}
@xrdef{Commands For Text-title}{Commands For Changing Text}
@xrdef{Commands For Text-snt}{Section@tie 8.4.3}
@xrdef{Commands For Text-pg}{108}
@xrdef{Commands For Text-pg}{110}
@xrdef{Commands For Killing-title}{Killing And Yanking}
@xrdef{Commands For Killing-snt}{Section@tie 8.4.4}
@xrdef{Commands For Killing-pg}{109}
@xrdef{Commands For Killing-pg}{111}
@xrdef{Numeric Arguments-title}{Specifying Numeric Arguments}
@xrdef{Numeric Arguments-snt}{Section@tie 8.4.5}
@xrdef{Commands For Completion-title}{Letting Readline Type For You}
@xrdef{Commands For Completion-snt}{Section@tie 8.4.6}
@xrdef{Numeric Arguments-pg}{110}
@xrdef{Commands For Completion-pg}{110}
@xrdef{Numeric Arguments-pg}{112}
@xrdef{Commands For Completion-pg}{112}
@xrdef{Keyboard Macros-title}{Keyboard Macros}
@xrdef{Keyboard Macros-snt}{Section@tie 8.4.7}
@xrdef{Miscellaneous Commands-title}{Some Miscellaneous Commands}
@xrdef{Miscellaneous Commands-snt}{Section@tie 8.4.8}
@xrdef{Keyboard Macros-pg}{112}
@xrdef{Miscellaneous Commands-pg}{112}
@xrdef{Keyboard Macros-pg}{114}
@xrdef{Miscellaneous Commands-pg}{114}
@xrdef{Readline vi Mode-title}{Readline vi Mode}
@xrdef{Readline vi Mode-snt}{Section@tie 8.5}
@xrdef{Programmable Completion-title}{Programmable Completion}
@xrdef{Programmable Completion-snt}{Section@tie 8.6}
@xrdef{Readline vi Mode-pg}{115}
@xrdef{Programmable Completion-pg}{115}
@xrdef{Readline vi Mode-pg}{117}
@xrdef{Programmable Completion-pg}{117}
@xrdef{Programmable Completion Builtins-title}{Programmable Completion Builtins}
@xrdef{Programmable Completion Builtins-snt}{Section@tie 8.7}
@xrdef{Programmable Completion Builtins-pg}{117}
@xrdef{Programmable Completion Builtins-pg}{119}
@xrdef{Using History Interactively-title}{Using History Interactively}
@xrdef{Using History Interactively-snt}{Chapter@tie 9}
@xrdef{Bash History Facilities-title}{Bash History Facilities}
@xrdef{Bash History Facilities-snt}{Section@tie 9.1}
@xrdef{Bash History Builtins-title}{Bash History Builtins}
@xrdef{Bash History Builtins-snt}{Section@tie 9.2}
@xrdef{Using History Interactively-pg}{121}
@xrdef{Bash History Facilities-pg}{121}
@xrdef{Bash History Builtins-pg}{121}
@xrdef{Using History Interactively-pg}{123}
@xrdef{Bash History Facilities-pg}{123}
@xrdef{Bash History Builtins-pg}{123}
@xrdef{History Interaction-title}{History Expansion}
@xrdef{History Interaction-snt}{Section@tie 9.3}
@xrdef{Event Designators-title}{Event Designators}
@xrdef{Event Designators-snt}{Section@tie 9.3.1}
@xrdef{History Interaction-pg}{123}
@xrdef{Event Designators-pg}{123}
@xrdef{History Interaction-pg}{125}
@xrdef{Event Designators-pg}{125}
@xrdef{Word Designators-title}{Word Designators}
@xrdef{Word Designators-snt}{Section@tie 9.3.2}
@xrdef{Word Designators-pg}{124}
@xrdef{Word Designators-pg}{126}
@xrdef{Modifiers-title}{Modifiers}
@xrdef{Modifiers-snt}{Section@tie 9.3.3}
@xrdef{Modifiers-pg}{125}
@xrdef{Modifiers-pg}{127}
@xrdef{Installing Bash-title}{Installing Bash}
@xrdef{Installing Bash-snt}{Chapter@tie 10}
@xrdef{Basic Installation-title}{Basic Installation}
@xrdef{Basic Installation-snt}{Section@tie 10.1}
@xrdef{Compilers and Options-title}{Compilers and Options}
@xrdef{Compilers and Options-snt}{Section@tie 10.2}
@xrdef{Installing Bash-pg}{127}
@xrdef{Basic Installation-pg}{127}
@xrdef{Installing Bash-pg}{129}
@xrdef{Basic Installation-pg}{129}
@xrdef{Compiling For Multiple Architectures-title}{Compiling For Multiple Architectures}
@xrdef{Compiling For Multiple Architectures-snt}{Section@tie 10.3}
@xrdef{Installation Names-title}{Installation Names}
@xrdef{Installation Names-snt}{Section@tie 10.4}
@xrdef{Specifying the System Type-title}{Specifying the System Type}
@xrdef{Specifying the System Type-snt}{Section@tie 10.5}
@xrdef{Compilers and Options-pg}{128}
@xrdef{Compiling For Multiple Architectures-pg}{128}
@xrdef{Installation Names-pg}{128}
@xrdef{Specifying the System Type-pg}{128}
@xrdef{Compilers and Options-pg}{130}
@xrdef{Compiling For Multiple Architectures-pg}{130}
@xrdef{Installation Names-pg}{130}
@xrdef{Specifying the System Type-pg}{130}
@xrdef{Sharing Defaults-title}{Sharing Defaults}
@xrdef{Sharing Defaults-snt}{Section@tie 10.6}
@xrdef{Operation Controls-title}{Operation Controls}
@xrdef{Operation Controls-snt}{Section@tie 10.7}
@xrdef{Optional Features-title}{Optional Features}
@xrdef{Optional Features-snt}{Section@tie 10.8}
@xrdef{Sharing Defaults-pg}{129}
@xrdef{Operation Controls-pg}{129}
@xrdef{Optional Features-pg}{129}
@xrdef{Sharing Defaults-pg}{131}
@xrdef{Operation Controls-pg}{131}
@xrdef{Optional Features-pg}{131}
@xrdef{Reporting Bugs-title}{Reporting Bugs}
@xrdef{Reporting Bugs-snt}{Appendix@tie @char65{}}
@xrdef{Reporting Bugs-pg}{135}
@xrdef{Reporting Bugs-pg}{137}
@xrdef{Major Differences From The Bourne Shell-title}{Major Differences From The Bourne Shell}
@xrdef{Major Differences From The Bourne Shell-snt}{Appendix@tie @char66{}}
@xrdef{Major Differences From The Bourne Shell-pg}{137}
@xrdef{Major Differences From The Bourne Shell-pg}{139}
@xrdef{GNU Free Documentation License-title}{GNU Free Documentation License}
@xrdef{GNU Free Documentation License-snt}{Appendix@tie @char67{}}
@xrdef{GNU Free Documentation License-pg}{143}
@xrdef{GNU Free Documentation License-pg}{145}
@xrdef{Indexes-title}{Indexes}
@xrdef{Indexes-snt}{Appendix@tie @char68{}}
@xrdef{Builtin Index-title}{Index of Shell Builtin Commands}
@xrdef{Builtin Index-snt}{Section@tie @char68.1}
@xrdef{Indexes-pg}{151}
@xrdef{Builtin Index-pg}{151}
@xrdef{Indexes-pg}{153}
@xrdef{Builtin Index-pg}{153}
@xrdef{Reserved Word Index-title}{Index of Shell Reserved Words}
@xrdef{Reserved Word Index-snt}{Section@tie @char68.2}
@xrdef{Variable Index-title}{Parameter and Variable Index}
@xrdef{Variable Index-snt}{Section@tie @char68.3}
@xrdef{Reserved Word Index-pg}{152}
@xrdef{Variable Index-pg}{152}
@xrdef{Reserved Word Index-pg}{154}
@xrdef{Variable Index-pg}{154}
@xrdef{Function Index-title}{Function Index}
@xrdef{Function Index-snt}{Section@tie @char68.4}
@xrdef{Function Index-pg}{154}
@xrdef{Function Index-pg}{156}
@xrdef{Concept Index-title}{Concept Index}
@xrdef{Concept Index-snt}{Section@tie @char68.5}
@xrdef{Concept Index-pg}{156}
@xrdef{Concept Index-pg}{158}
+59 -59
View File
@@ -1,59 +1,59 @@
\entry{:}{35}{\code {:}}
\entry{.}{35}{\code {.}}
\entry{break}{35}{\code {break}}
\entry{cd}{36}{\code {cd}}
\entry{continue}{36}{\code {continue}}
\entry{eval}{36}{\code {eval}}
\entry{exec}{36}{\code {exec}}
\entry{exit}{36}{\code {exit}}
\entry{export}{36}{\code {export}}
\entry{getopts}{37}{\code {getopts}}
\entry{hash}{37}{\code {hash}}
\entry{pwd}{38}{\code {pwd}}
\entry{readonly}{38}{\code {readonly}}
\entry{return}{38}{\code {return}}
\entry{shift}{38}{\code {shift}}
\entry{test}{39}{\code {test}}
\entry{[}{39}{\code {[}}
\entry{times}{40}{\code {times}}
\entry{trap}{40}{\code {trap}}
\entry{umask}{41}{\code {umask}}
\entry{unset}{41}{\code {unset}}
\entry{alias}{41}{\code {alias}}
\entry{bind}{41}{\code {bind}}
\entry{builtin}{43}{\code {builtin}}
\entry{caller}{43}{\code {caller}}
\entry{command}{43}{\code {command}}
\entry{declare}{43}{\code {declare}}
\entry{echo}{45}{\code {echo}}
\entry{enable}{45}{\code {enable}}
\entry{help}{46}{\code {help}}
\entry{let}{46}{\code {let}}
\entry{local}{46}{\code {local}}
\entry{logout}{46}{\code {logout}}
\entry{mapfile}{46}{\code {mapfile}}
\entry{printf}{47}{\code {printf}}
\entry{read}{47}{\code {read}}
\entry{readarray}{49}{\code {readarray}}
\entry{source}{49}{\code {source}}
\entry{type}{49}{\code {type}}
\entry{typeset}{49}{\code {typeset}}
\entry{ulimit}{50}{\code {ulimit}}
\entry{unalias}{51}{\code {unalias}}
\entry{set}{51}{\code {set}}
\entry{shopt}{55}{\code {shopt}}
\entry{dirs}{81}{\code {dirs}}
\entry{popd}{82}{\code {popd}}
\entry{pushd}{82}{\code {pushd}}
\entry{bg}{90}{\code {bg}}
\entry{fg}{90}{\code {fg}}
\entry{jobs}{90}{\code {jobs}}
\entry{kill}{91}{\code {kill}}
\entry{wait}{91}{\code {wait}}
\entry{disown}{91}{\code {disown}}
\entry{suspend}{91}{\code {suspend}}
\entry{compgen}{117}{\code {compgen}}
\entry{complete}{117}{\code {complete}}
\entry{compopt}{120}{\code {compopt}}
\entry{fc}{121}{\code {fc}}
\entry{history}{122}{\code {history}}
\entry{:}{37}{\code {:}}
\entry{.}{37}{\code {.}}
\entry{break}{37}{\code {break}}
\entry{cd}{38}{\code {cd}}
\entry{continue}{38}{\code {continue}}
\entry{eval}{38}{\code {eval}}
\entry{exec}{38}{\code {exec}}
\entry{exit}{38}{\code {exit}}
\entry{export}{38}{\code {export}}
\entry{getopts}{39}{\code {getopts}}
\entry{hash}{39}{\code {hash}}
\entry{pwd}{40}{\code {pwd}}
\entry{readonly}{40}{\code {readonly}}
\entry{return}{40}{\code {return}}
\entry{shift}{40}{\code {shift}}
\entry{test}{41}{\code {test}}
\entry{[}{41}{\code {[}}
\entry{times}{42}{\code {times}}
\entry{trap}{42}{\code {trap}}
\entry{umask}{43}{\code {umask}}
\entry{unset}{43}{\code {unset}}
\entry{alias}{43}{\code {alias}}
\entry{bind}{43}{\code {bind}}
\entry{builtin}{45}{\code {builtin}}
\entry{caller}{45}{\code {caller}}
\entry{command}{45}{\code {command}}
\entry{declare}{45}{\code {declare}}
\entry{echo}{47}{\code {echo}}
\entry{enable}{47}{\code {enable}}
\entry{help}{48}{\code {help}}
\entry{let}{48}{\code {let}}
\entry{local}{48}{\code {local}}
\entry{logout}{48}{\code {logout}}
\entry{mapfile}{49}{\code {mapfile}}
\entry{printf}{49}{\code {printf}}
\entry{read}{50}{\code {read}}
\entry{readarray}{51}{\code {readarray}}
\entry{source}{51}{\code {source}}
\entry{type}{51}{\code {type}}
\entry{typeset}{52}{\code {typeset}}
\entry{ulimit}{52}{\code {ulimit}}
\entry{unalias}{53}{\code {unalias}}
\entry{set}{53}{\code {set}}
\entry{shopt}{57}{\code {shopt}}
\entry{dirs}{83}{\code {dirs}}
\entry{popd}{84}{\code {popd}}
\entry{pushd}{84}{\code {pushd}}
\entry{bg}{92}{\code {bg}}
\entry{fg}{92}{\code {fg}}
\entry{jobs}{92}{\code {jobs}}
\entry{kill}{93}{\code {kill}}
\entry{wait}{93}{\code {wait}}
\entry{disown}{93}{\code {disown}}
\entry{suspend}{93}{\code {suspend}}
\entry{compgen}{119}{\code {compgen}}
\entry{complete}{119}{\code {complete}}
\entry{compopt}{122}{\code {compopt}}
\entry{fc}{123}{\code {fc}}
\entry{history}{124}{\code {history}}
+59 -59
View File
@@ -1,80 +1,80 @@
\initial {.}
\entry {\code {.}}{35}
\entry {\code {.}}{37}
\initial {:}
\entry {\code {:}}{35}
\entry {\code {:}}{37}
\initial {[}
\entry {\code {[}}{39}
\entry {\code {[}}{41}
\initial {A}
\entry {\code {alias}}{41}
\entry {\code {alias}}{43}
\initial {B}
\entry {\code {bg}}{90}
\entry {\code {bind}}{41}
\entry {\code {break}}{35}
\entry {\code {builtin}}{43}
\entry {\code {bg}}{92}
\entry {\code {bind}}{43}
\entry {\code {break}}{37}
\entry {\code {builtin}}{45}
\initial {C}
\entry {\code {caller}}{43}
\entry {\code {cd}}{36}
\entry {\code {command}}{43}
\entry {\code {compgen}}{117}
\entry {\code {complete}}{117}
\entry {\code {compopt}}{120}
\entry {\code {continue}}{36}
\entry {\code {caller}}{45}
\entry {\code {cd}}{38}
\entry {\code {command}}{45}
\entry {\code {compgen}}{119}
\entry {\code {complete}}{119}
\entry {\code {compopt}}{122}
\entry {\code {continue}}{38}
\initial {D}
\entry {\code {declare}}{43}
\entry {\code {dirs}}{81}
\entry {\code {disown}}{91}
\entry {\code {declare}}{45}
\entry {\code {dirs}}{83}
\entry {\code {disown}}{93}
\initial {E}
\entry {\code {echo}}{45}
\entry {\code {enable}}{45}
\entry {\code {eval}}{36}
\entry {\code {exec}}{36}
\entry {\code {exit}}{36}
\entry {\code {export}}{36}
\entry {\code {echo}}{47}
\entry {\code {enable}}{47}
\entry {\code {eval}}{38}
\entry {\code {exec}}{38}
\entry {\code {exit}}{38}
\entry {\code {export}}{38}
\initial {F}
\entry {\code {fc}}{121}
\entry {\code {fg}}{90}
\entry {\code {fc}}{123}
\entry {\code {fg}}{92}
\initial {G}
\entry {\code {getopts}}{37}
\entry {\code {getopts}}{39}
\initial {H}
\entry {\code {hash}}{37}
\entry {\code {help}}{46}
\entry {\code {history}}{122}
\entry {\code {hash}}{39}
\entry {\code {help}}{48}
\entry {\code {history}}{124}
\initial {J}
\entry {\code {jobs}}{90}
\entry {\code {jobs}}{92}
\initial {K}
\entry {\code {kill}}{91}
\entry {\code {kill}}{93}
\initial {L}
\entry {\code {let}}{46}
\entry {\code {local}}{46}
\entry {\code {logout}}{46}
\entry {\code {let}}{48}
\entry {\code {local}}{48}
\entry {\code {logout}}{48}
\initial {M}
\entry {\code {mapfile}}{46}
\entry {\code {mapfile}}{49}
\initial {P}
\entry {\code {popd}}{82}
\entry {\code {printf}}{47}
\entry {\code {pushd}}{82}
\entry {\code {pwd}}{38}
\entry {\code {popd}}{84}
\entry {\code {printf}}{49}
\entry {\code {pushd}}{84}
\entry {\code {pwd}}{40}
\initial {R}
\entry {\code {read}}{47}
\entry {\code {readarray}}{49}
\entry {\code {readonly}}{38}
\entry {\code {return}}{38}
\entry {\code {read}}{50}
\entry {\code {readarray}}{51}
\entry {\code {readonly}}{40}
\entry {\code {return}}{40}
\initial {S}
\entry {\code {set}}{51}
\entry {\code {shift}}{38}
\entry {\code {shopt}}{55}
\entry {\code {source}}{49}
\entry {\code {suspend}}{91}
\entry {\code {set}}{53}
\entry {\code {shift}}{40}
\entry {\code {shopt}}{57}
\entry {\code {source}}{51}
\entry {\code {suspend}}{93}
\initial {T}
\entry {\code {test}}{39}
\entry {\code {times}}{40}
\entry {\code {trap}}{40}
\entry {\code {type}}{49}
\entry {\code {typeset}}{49}
\entry {\code {test}}{41}
\entry {\code {times}}{42}
\entry {\code {trap}}{42}
\entry {\code {type}}{51}
\entry {\code {typeset}}{52}
\initial {U}
\entry {\code {ulimit}}{50}
\entry {\code {umask}}{41}
\entry {\code {unalias}}{51}
\entry {\code {unset}}{41}
\entry {\code {ulimit}}{52}
\entry {\code {umask}}{43}
\entry {\code {unalias}}{53}
\entry {\code {unset}}{43}
\initial {W}
\entry {\code {wait}}{91}
\entry {\code {wait}}{93}
+82 -82
View File
@@ -26,93 +26,93 @@
\entry{native languages}{7}{native languages}
\entry{translation, native languages}{7}{translation, native languages}
\entry{comments, shell}{7}{comments, shell}
\entry{commands, shell}{7}{commands, shell}
\entry{commands, shell}{8}{commands, shell}
\entry{commands, simple}{8}{commands, simple}
\entry{pipeline}{8}{pipeline}
\entry{commands, pipelines}{8}{commands, pipelines}
\entry{command timing}{8}{command timing}
\entry{commands, lists}{8}{commands, lists}
\entry{commands, lists}{9}{commands, lists}
\entry{commands, compound}{9}{commands, compound}
\entry{commands, looping}{9}{commands, looping}
\entry{commands, looping}{10}{commands, looping}
\entry{commands, conditional}{10}{commands, conditional}
\entry{commands, grouping}{13}{commands, grouping}
\entry{coprocess}{14}{coprocess}
\entry{shell function}{14}{shell function}
\entry{functions, shell}{14}{functions, shell}
\entry{parameters}{15}{parameters}
\entry{variable, shell}{15}{variable, shell}
\entry{shell variable}{15}{shell variable}
\entry{parameters, positional}{16}{parameters, positional}
\entry{parameters, special}{16}{parameters, special}
\entry{expansion}{17}{expansion}
\entry{brace expansion}{18}{brace expansion}
\entry{expansion, brace}{18}{expansion, brace}
\entry{tilde expansion}{19}{tilde expansion}
\entry{expansion, tilde}{19}{expansion, tilde}
\entry{parameter expansion}{19}{parameter expansion}
\entry{expansion, parameter}{19}{expansion, parameter}
\entry{command substitution}{22}{command substitution}
\entry{expansion, arithmetic}{23}{expansion, arithmetic}
\entry{arithmetic expansion}{23}{arithmetic expansion}
\entry{process substitution}{23}{process substitution}
\entry{word splitting}{23}{word splitting}
\entry{expansion, filename}{24}{expansion, filename}
\entry{expansion, pathname}{24}{expansion, pathname}
\entry{filename expansion}{24}{filename expansion}
\entry{pathname expansion}{24}{pathname expansion}
\entry{pattern matching}{24}{pattern matching}
\entry{matching, pattern}{24}{matching, pattern}
\entry{redirection}{26}{redirection}
\entry{command expansion}{29}{command expansion}
\entry{command execution}{30}{command execution}
\entry{command search}{30}{command search}
\entry{execution environment}{30}{execution environment}
\entry{environment}{31}{environment}
\entry{exit status}{32}{exit status}
\entry{signal handling}{32}{signal handling}
\entry{shell script}{33}{shell script}
\entry{special builtin}{59}{special builtin}
\entry{login shell}{73}{login shell}
\entry{interactive shell}{73}{interactive shell}
\entry{startup files}{73}{startup files}
\entry{interactive shell}{74}{interactive shell}
\entry{shell, interactive}{74}{shell, interactive}
\entry{expressions, conditional}{76}{expressions, conditional}
\entry{arithmetic, shell}{78}{arithmetic, shell}
\entry{shell arithmetic}{78}{shell arithmetic}
\entry{expressions, arithmetic}{78}{expressions, arithmetic}
\entry{evaluation, arithmetic}{78}{evaluation, arithmetic}
\entry{arithmetic evaluation}{78}{arithmetic evaluation}
\entry{alias expansion}{79}{alias expansion}
\entry{arrays}{80}{arrays}
\entry{directory stack}{81}{directory stack}
\entry{prompting}{82}{prompting}
\entry{restricted shell}{84}{restricted shell}
\entry{POSIX Mode}{84}{POSIX Mode}
\entry{job control}{89}{job control}
\entry{foreground}{89}{foreground}
\entry{background}{89}{background}
\entry{suspending jobs}{89}{suspending jobs}
\entry{Readline, how to use}{92}{Readline, how to use}
\entry{interaction, readline}{93}{interaction, readline}
\entry{notation, readline}{94}{notation, readline}
\entry{command editing}{94}{command editing}
\entry{editing command lines}{94}{editing command lines}
\entry{killing text}{95}{killing text}
\entry{yanking text}{95}{yanking text}
\entry{kill ring}{95}{kill ring}
\entry{initialization file, readline}{96}{initialization file, readline}
\entry{variables, readline}{97}{variables, readline}
\entry{programmable completion}{115}{programmable completion}
\entry{completion builtins}{117}{completion builtins}
\entry{History, how to use}{120}{History, how to use}
\entry{command history}{121}{command history}
\entry{history list}{121}{history list}
\entry{history builtins}{121}{history builtins}
\entry{history expansion}{123}{history expansion}
\entry{event designators}{123}{event designators}
\entry{history events}{123}{history events}
\entry{installation}{127}{installation}
\entry{configuration}{127}{configuration}
\entry{Bash installation}{127}{Bash installation}
\entry{Bash configuration}{127}{Bash configuration}
\entry{shell function}{15}{shell function}
\entry{functions, shell}{15}{functions, shell}
\entry{parameters}{17}{parameters}
\entry{variable, shell}{17}{variable, shell}
\entry{shell variable}{17}{shell variable}
\entry{parameters, positional}{17}{parameters, positional}
\entry{parameters, special}{18}{parameters, special}
\entry{expansion}{18}{expansion}
\entry{brace expansion}{19}{brace expansion}
\entry{expansion, brace}{19}{expansion, brace}
\entry{tilde expansion}{20}{tilde expansion}
\entry{expansion, tilde}{20}{expansion, tilde}
\entry{parameter expansion}{21}{parameter expansion}
\entry{expansion, parameter}{21}{expansion, parameter}
\entry{command substitution}{24}{command substitution}
\entry{expansion, arithmetic}{24}{expansion, arithmetic}
\entry{arithmetic expansion}{24}{arithmetic expansion}
\entry{process substitution}{24}{process substitution}
\entry{word splitting}{25}{word splitting}
\entry{expansion, filename}{25}{expansion, filename}
\entry{expansion, pathname}{25}{expansion, pathname}
\entry{filename expansion}{25}{filename expansion}
\entry{pathname expansion}{25}{pathname expansion}
\entry{pattern matching}{26}{pattern matching}
\entry{matching, pattern}{26}{matching, pattern}
\entry{redirection}{27}{redirection}
\entry{command expansion}{30}{command expansion}
\entry{command execution}{31}{command execution}
\entry{command search}{31}{command search}
\entry{execution environment}{32}{execution environment}
\entry{environment}{33}{environment}
\entry{exit status}{33}{exit status}
\entry{signal handling}{34}{signal handling}
\entry{shell script}{34}{shell script}
\entry{special builtin}{62}{special builtin}
\entry{login shell}{75}{login shell}
\entry{interactive shell}{75}{interactive shell}
\entry{startup files}{75}{startup files}
\entry{interactive shell}{76}{interactive shell}
\entry{shell, interactive}{76}{shell, interactive}
\entry{expressions, conditional}{78}{expressions, conditional}
\entry{arithmetic, shell}{80}{arithmetic, shell}
\entry{shell arithmetic}{80}{shell arithmetic}
\entry{expressions, arithmetic}{80}{expressions, arithmetic}
\entry{evaluation, arithmetic}{80}{evaluation, arithmetic}
\entry{arithmetic evaluation}{80}{arithmetic evaluation}
\entry{alias expansion}{81}{alias expansion}
\entry{arrays}{82}{arrays}
\entry{directory stack}{83}{directory stack}
\entry{prompting}{84}{prompting}
\entry{restricted shell}{86}{restricted shell}
\entry{POSIX Mode}{86}{POSIX Mode}
\entry{job control}{91}{job control}
\entry{foreground}{91}{foreground}
\entry{background}{91}{background}
\entry{suspending jobs}{91}{suspending jobs}
\entry{Readline, how to use}{94}{Readline, how to use}
\entry{interaction, readline}{95}{interaction, readline}
\entry{notation, readline}{96}{notation, readline}
\entry{command editing}{96}{command editing}
\entry{editing command lines}{96}{editing command lines}
\entry{killing text}{97}{killing text}
\entry{yanking text}{97}{yanking text}
\entry{kill ring}{97}{kill ring}
\entry{initialization file, readline}{98}{initialization file, readline}
\entry{variables, readline}{99}{variables, readline}
\entry{programmable completion}{117}{programmable completion}
\entry{completion builtins}{119}{completion builtins}
\entry{History, how to use}{122}{History, how to use}
\entry{command history}{123}{command history}
\entry{history list}{123}{history list}
\entry{history builtins}{123}{history builtins}
\entry{history expansion}{125}{history expansion}
\entry{event designators}{125}{event designators}
\entry{history events}{125}{history events}
\entry{installation}{129}{installation}
\entry{configuration}{129}{configuration}
\entry{Bash installation}{129}{Bash installation}
\entry{Bash configuration}{129}{Bash configuration}
+81 -81
View File
@@ -1,136 +1,136 @@
\initial {A}
\entry {alias expansion}{79}
\entry {arithmetic evaluation}{78}
\entry {arithmetic expansion}{23}
\entry {arithmetic, shell}{78}
\entry {arrays}{80}
\entry {alias expansion}{81}
\entry {arithmetic evaluation}{80}
\entry {arithmetic expansion}{24}
\entry {arithmetic, shell}{80}
\entry {arrays}{82}
\initial {B}
\entry {background}{89}
\entry {Bash configuration}{127}
\entry {Bash installation}{127}
\entry {background}{91}
\entry {Bash configuration}{129}
\entry {Bash installation}{129}
\entry {Bourne shell}{5}
\entry {brace expansion}{18}
\entry {brace expansion}{19}
\entry {builtin}{3}
\initial {C}
\entry {command editing}{94}
\entry {command execution}{30}
\entry {command expansion}{29}
\entry {command history}{121}
\entry {command search}{30}
\entry {command substitution}{22}
\entry {command editing}{96}
\entry {command execution}{31}
\entry {command expansion}{30}
\entry {command history}{123}
\entry {command search}{31}
\entry {command substitution}{24}
\entry {command timing}{8}
\entry {commands, compound}{9}
\entry {commands, conditional}{10}
\entry {commands, grouping}{13}
\entry {commands, lists}{8}
\entry {commands, looping}{9}
\entry {commands, lists}{9}
\entry {commands, looping}{10}
\entry {commands, pipelines}{8}
\entry {commands, shell}{7}
\entry {commands, shell}{8}
\entry {commands, simple}{8}
\entry {comments, shell}{7}
\entry {completion builtins}{117}
\entry {configuration}{127}
\entry {completion builtins}{119}
\entry {configuration}{129}
\entry {control operator}{3}
\entry {coprocess}{14}
\initial {D}
\entry {directory stack}{81}
\entry {directory stack}{83}
\initial {E}
\entry {editing command lines}{94}
\entry {environment}{31}
\entry {evaluation, arithmetic}{78}
\entry {event designators}{123}
\entry {execution environment}{30}
\entry {exit status}{3, 32}
\entry {expansion}{17}
\entry {expansion, arithmetic}{23}
\entry {expansion, brace}{18}
\entry {expansion, filename}{24}
\entry {expansion, parameter}{19}
\entry {expansion, pathname}{24}
\entry {expansion, tilde}{19}
\entry {expressions, arithmetic}{78}
\entry {expressions, conditional}{76}
\entry {editing command lines}{96}
\entry {environment}{33}
\entry {evaluation, arithmetic}{80}
\entry {event designators}{125}
\entry {execution environment}{32}
\entry {exit status}{3, 33}
\entry {expansion}{18}
\entry {expansion, arithmetic}{24}
\entry {expansion, brace}{19}
\entry {expansion, filename}{25}
\entry {expansion, parameter}{21}
\entry {expansion, pathname}{25}
\entry {expansion, tilde}{20}
\entry {expressions, arithmetic}{80}
\entry {expressions, conditional}{78}
\initial {F}
\entry {field}{3}
\entry {filename}{3}
\entry {filename expansion}{24}
\entry {foreground}{89}
\entry {functions, shell}{14}
\entry {filename expansion}{25}
\entry {foreground}{91}
\entry {functions, shell}{15}
\initial {H}
\entry {history builtins}{121}
\entry {history events}{123}
\entry {history expansion}{123}
\entry {history list}{121}
\entry {History, how to use}{120}
\entry {history builtins}{123}
\entry {history events}{125}
\entry {history expansion}{125}
\entry {history list}{123}
\entry {History, how to use}{122}
\initial {I}
\entry {identifier}{3}
\entry {initialization file, readline}{96}
\entry {installation}{127}
\entry {interaction, readline}{93}
\entry {interactive shell}{73, 74}
\entry {initialization file, readline}{98}
\entry {installation}{129}
\entry {interaction, readline}{95}
\entry {interactive shell}{75, 76}
\entry {internationalization}{7}
\initial {J}
\entry {job}{3}
\entry {job control}{3, 89}
\entry {job control}{3, 91}
\initial {K}
\entry {kill ring}{95}
\entry {killing text}{95}
\entry {kill ring}{97}
\entry {killing text}{97}
\initial {L}
\entry {localization}{7}
\entry {login shell}{73}
\entry {login shell}{75}
\initial {M}
\entry {matching, pattern}{24}
\entry {matching, pattern}{26}
\entry {metacharacter}{3}
\initial {N}
\entry {name}{3}
\entry {native languages}{7}
\entry {notation, readline}{94}
\entry {notation, readline}{96}
\initial {O}
\entry {operator, shell}{3}
\initial {P}
\entry {parameter expansion}{19}
\entry {parameters}{15}
\entry {parameters, positional}{16}
\entry {parameters, special}{16}
\entry {pathname expansion}{24}
\entry {pattern matching}{24}
\entry {parameter expansion}{21}
\entry {parameters}{17}
\entry {parameters, positional}{17}
\entry {parameters, special}{18}
\entry {pathname expansion}{25}
\entry {pattern matching}{26}
\entry {pipeline}{8}
\entry {POSIX}{3}
\entry {POSIX Mode}{84}
\entry {POSIX Mode}{86}
\entry {process group}{3}
\entry {process group ID}{3}
\entry {process substitution}{23}
\entry {programmable completion}{115}
\entry {prompting}{82}
\entry {process substitution}{24}
\entry {programmable completion}{117}
\entry {prompting}{84}
\initial {Q}
\entry {quoting}{6}
\entry {quoting, ANSI}{6}
\initial {R}
\entry {Readline, how to use}{92}
\entry {redirection}{26}
\entry {Readline, how to use}{94}
\entry {redirection}{27}
\entry {reserved word}{3}
\entry {restricted shell}{84}
\entry {restricted shell}{86}
\entry {return status}{4}
\initial {S}
\entry {shell arithmetic}{78}
\entry {shell function}{14}
\entry {shell script}{33}
\entry {shell variable}{15}
\entry {shell, interactive}{74}
\entry {shell arithmetic}{80}
\entry {shell function}{15}
\entry {shell script}{34}
\entry {shell variable}{17}
\entry {shell, interactive}{76}
\entry {signal}{4}
\entry {signal handling}{32}
\entry {special builtin}{4, 59}
\entry {startup files}{73}
\entry {suspending jobs}{89}
\entry {signal handling}{34}
\entry {special builtin}{4, 62}
\entry {startup files}{75}
\entry {suspending jobs}{91}
\initial {T}
\entry {tilde expansion}{19}
\entry {tilde expansion}{20}
\entry {token}{4}
\entry {translation, native languages}{7}
\initial {V}
\entry {variable, shell}{15}
\entry {variables, readline}{97}
\entry {variable, shell}{17}
\entry {variables, readline}{99}
\initial {W}
\entry {word}{4}
\entry {word splitting}{23}
\entry {word splitting}{25}
\initial {Y}
\entry {yanking text}{95}
\entry {yanking text}{97}
BIN
View File
Binary file not shown.
+103 -103
View File
@@ -1,103 +1,103 @@
\entry{beginning-of-line (C-a)}{106}{\code {beginning-of-line (C-a)}}
\entry{end-of-line (C-e)}{106}{\code {end-of-line (C-e)}}
\entry{forward-char (C-f)}{106}{\code {forward-char (C-f)}}
\entry{backward-char (C-b)}{106}{\code {backward-char (C-b)}}
\entry{forward-word (M-f)}{106}{\code {forward-word (M-f)}}
\entry{backward-word (M-b)}{106}{\code {backward-word (M-b)}}
\entry{shell-forward-word ()}{106}{\code {shell-forward-word ()}}
\entry{shell-backward-word ()}{106}{\code {shell-backward-word ()}}
\entry{clear-screen (C-l)}{106}{\code {clear-screen (C-l)}}
\entry{redraw-current-line ()}{106}{\code {redraw-current-line ()}}
\entry{accept-line (Newline or Return)}{107}{\code {accept-line (Newline or Return)}}
\entry{previous-history (C-p)}{107}{\code {previous-history (C-p)}}
\entry{next-history (C-n)}{107}{\code {next-history (C-n)}}
\entry{beginning-of-history (M-<)}{107}{\code {beginning-of-history (M-<)}}
\entry{end-of-history (M->)}{107}{\code {end-of-history (M->)}}
\entry{reverse-search-history (C-r)}{107}{\code {reverse-search-history (C-r)}}
\entry{forward-search-history (C-s)}{107}{\code {forward-search-history (C-s)}}
\entry{non-incremental-reverse-search-history (M-p)}{107}{\code {non-incremental-reverse-search-history (M-p)}}
\entry{non-incremental-forward-search-history (M-n)}{107}{\code {non-incremental-forward-search-history (M-n)}}
\entry{history-search-forward ()}{107}{\code {history-search-forward ()}}
\entry{history-search-backward ()}{107}{\code {history-search-backward ()}}
\entry{yank-nth-arg (M-C-y)}{107}{\code {yank-nth-arg (M-C-y)}}
\entry{yank-last-arg (M-. or M-_)}{108}{\code {yank-last-arg (M-. or M-_)}}
\entry{delete-char (C-d)}{108}{\code {delete-char (C-d)}}
\entry{backward-delete-char (Rubout)}{108}{\code {backward-delete-char (Rubout)}}
\entry{forward-backward-delete-char ()}{108}{\code {forward-backward-delete-char ()}}
\entry{quoted-insert (C-q or C-v)}{108}{\code {quoted-insert (C-q or C-v)}}
\entry{self-insert (a, b, A, 1, !, ...{})}{108}{\code {self-insert (a, b, A, 1, !, \dots {})}}
\entry{transpose-chars (C-t)}{108}{\code {transpose-chars (C-t)}}
\entry{transpose-words (M-t)}{108}{\code {transpose-words (M-t)}}
\entry{upcase-word (M-u)}{108}{\code {upcase-word (M-u)}}
\entry{downcase-word (M-l)}{108}{\code {downcase-word (M-l)}}
\entry{capitalize-word (M-c)}{109}{\code {capitalize-word (M-c)}}
\entry{overwrite-mode ()}{109}{\code {overwrite-mode ()}}
\entry{kill-line (C-k)}{109}{\code {kill-line (C-k)}}
\entry{backward-kill-line (C-x Rubout)}{109}{\code {backward-kill-line (C-x Rubout)}}
\entry{unix-line-discard (C-u)}{109}{\code {unix-line-discard (C-u)}}
\entry{kill-whole-line ()}{109}{\code {kill-whole-line ()}}
\entry{kill-word (M-d)}{109}{\code {kill-word (M-d)}}
\entry{backward-kill-word (M-DEL)}{109}{\code {backward-kill-word (M-\key {DEL})}}
\entry{shell-kill-word ()}{109}{\code {shell-kill-word ()}}
\entry{backward-kill-word ()}{109}{\code {backward-kill-word ()}}
\entry{unix-word-rubout (C-w)}{109}{\code {unix-word-rubout (C-w)}}
\entry{unix-filename-rubout ()}{109}{\code {unix-filename-rubout ()}}
\entry{delete-horizontal-space ()}{109}{\code {delete-horizontal-space ()}}
\entry{kill-region ()}{110}{\code {kill-region ()}}
\entry{copy-region-as-kill ()}{110}{\code {copy-region-as-kill ()}}
\entry{copy-backward-word ()}{110}{\code {copy-backward-word ()}}
\entry{copy-forward-word ()}{110}{\code {copy-forward-word ()}}
\entry{yank (C-y)}{110}{\code {yank (C-y)}}
\entry{yank-pop (M-y)}{110}{\code {yank-pop (M-y)}}
\entry{digit-argument (M-0, M-1, ...{} M--)}{110}{\code {digit-argument (\kbd {M-0}, \kbd {M-1}, \dots {} \kbd {M--})}}
\entry{universal-argument ()}{110}{\code {universal-argument ()}}
\entry{complete (TAB)}{110}{\code {complete (\key {TAB})}}
\entry{possible-completions (M-?)}{110}{\code {possible-completions (M-?)}}
\entry{insert-completions (M-*)}{111}{\code {insert-completions (M-*)}}
\entry{menu-complete ()}{111}{\code {menu-complete ()}}
\entry{menu-complete-backward ()}{111}{\code {menu-complete-backward ()}}
\entry{delete-char-or-list ()}{111}{\code {delete-char-or-list ()}}
\entry{complete-filename (M-/)}{111}{\code {complete-filename (M-/)}}
\entry{possible-filename-completions (C-x /)}{111}{\code {possible-filename-completions (C-x /)}}
\entry{complete-username (M-~)}{111}{\code {complete-username (M-~)}}
\entry{possible-username-completions (C-x ~)}{111}{\code {possible-username-completions (C-x ~)}}
\entry{complete-variable (M-$)}{111}{\code {complete-variable (M-$)}}
\entry{possible-variable-completions (C-x $)}{111}{\code {possible-variable-completions (C-x $)}}
\entry{complete-hostname (M-@)}{111}{\code {complete-hostname (M-@)}}
\entry{possible-hostname-completions (C-x @)}{111}{\code {possible-hostname-completions (C-x @)}}
\entry{complete-command (M-!)}{111}{\code {complete-command (M-!)}}
\entry{possible-command-completions (C-x !)}{112}{\code {possible-command-completions (C-x !)}}
\entry{dynamic-complete-history (M-TAB)}{112}{\code {dynamic-complete-history (M-\key {TAB})}}
\entry{dabbrev-expand ()}{112}{\code {dabbrev-expand ()}}
\entry{complete-into-braces (M-{\tt \char 123})}{112}{\code {complete-into-braces (M-{\tt \char 123})}}
\entry{start-kbd-macro (C-x ()}{112}{\code {start-kbd-macro (C-x ()}}
\entry{end-kbd-macro (C-x ))}{112}{\code {end-kbd-macro (C-x ))}}
\entry{call-last-kbd-macro (C-x e)}{112}{\code {call-last-kbd-macro (C-x e)}}
\entry{re-read-init-file (C-x C-r)}{112}{\code {re-read-init-file (C-x C-r)}}
\entry{abort (C-g)}{112}{\code {abort (C-g)}}
\entry{do-uppercase-version (M-a, M-b, M-x, ...{})}{112}{\code {do-uppercase-version (M-a, M-b, M-\var {x}, \dots {})}}
\entry{prefix-meta (ESC)}{112}{\code {prefix-meta (\key {ESC})}}
\entry{undo (C-_ or C-x C-u)}{112}{\code {undo (C-_ or C-x C-u)}}
\entry{revert-line (M-r)}{113}{\code {revert-line (M-r)}}
\entry{tilde-expand (M-&)}{113}{\code {tilde-expand (M-&)}}
\entry{set-mark (C-@)}{113}{\code {set-mark (C-@)}}
\entry{exchange-point-and-mark (C-x C-x)}{113}{\code {exchange-point-and-mark (C-x C-x)}}
\entry{character-search (C-])}{113}{\code {character-search (C-])}}
\entry{character-search-backward (M-C-])}{113}{\code {character-search-backward (M-C-])}}
\entry{skip-csi-sequence ()}{113}{\code {skip-csi-sequence ()}}
\entry{insert-comment (M-#)}{113}{\code {insert-comment (M-#)}}
\entry{dump-functions ()}{113}{\code {dump-functions ()}}
\entry{dump-variables ()}{113}{\code {dump-variables ()}}
\entry{dump-macros ()}{114}{\code {dump-macros ()}}
\entry{glob-complete-word (M-g)}{114}{\code {glob-complete-word (M-g)}}
\entry{glob-expand-word (C-x *)}{114}{\code {glob-expand-word (C-x *)}}
\entry{glob-list-expansions (C-x g)}{114}{\code {glob-list-expansions (C-x g)}}
\entry{display-shell-version (C-x C-v)}{114}{\code {display-shell-version (C-x C-v)}}
\entry{shell-expand-line (M-C-e)}{114}{\code {shell-expand-line (M-C-e)}}
\entry{history-expand-line (M-^)}{114}{\code {history-expand-line (M-^)}}
\entry{magic-space ()}{114}{\code {magic-space ()}}
\entry{alias-expand-line ()}{114}{\code {alias-expand-line ()}}
\entry{history-and-alias-expand-line ()}{114}{\code {history-and-alias-expand-line ()}}
\entry{insert-last-argument (M-. or M-_)}{114}{\code {insert-last-argument (M-. or M-_)}}
\entry{operate-and-get-next (C-o)}{114}{\code {operate-and-get-next (C-o)}}
\entry{edit-and-execute-command (C-xC-e)}{114}{\code {edit-and-execute-command (C-xC-e)}}
\entry{beginning-of-line (C-a)}{108}{\code {beginning-of-line (C-a)}}
\entry{end-of-line (C-e)}{108}{\code {end-of-line (C-e)}}
\entry{forward-char (C-f)}{108}{\code {forward-char (C-f)}}
\entry{backward-char (C-b)}{108}{\code {backward-char (C-b)}}
\entry{forward-word (M-f)}{108}{\code {forward-word (M-f)}}
\entry{backward-word (M-b)}{108}{\code {backward-word (M-b)}}
\entry{shell-forward-word ()}{108}{\code {shell-forward-word ()}}
\entry{shell-backward-word ()}{108}{\code {shell-backward-word ()}}
\entry{clear-screen (C-l)}{108}{\code {clear-screen (C-l)}}
\entry{redraw-current-line ()}{108}{\code {redraw-current-line ()}}
\entry{accept-line (Newline or Return)}{109}{\code {accept-line (Newline or Return)}}
\entry{previous-history (C-p)}{109}{\code {previous-history (C-p)}}
\entry{next-history (C-n)}{109}{\code {next-history (C-n)}}
\entry{beginning-of-history (M-<)}{109}{\code {beginning-of-history (M-<)}}
\entry{end-of-history (M->)}{109}{\code {end-of-history (M->)}}
\entry{reverse-search-history (C-r)}{109}{\code {reverse-search-history (C-r)}}
\entry{forward-search-history (C-s)}{109}{\code {forward-search-history (C-s)}}
\entry{non-incremental-reverse-search-history (M-p)}{109}{\code {non-incremental-reverse-search-history (M-p)}}
\entry{non-incremental-forward-search-history (M-n)}{109}{\code {non-incremental-forward-search-history (M-n)}}
\entry{history-search-forward ()}{109}{\code {history-search-forward ()}}
\entry{history-search-backward ()}{109}{\code {history-search-backward ()}}
\entry{yank-nth-arg (M-C-y)}{109}{\code {yank-nth-arg (M-C-y)}}
\entry{yank-last-arg (M-. or M-_)}{110}{\code {yank-last-arg (M-. or M-_)}}
\entry{delete-char (C-d)}{110}{\code {delete-char (C-d)}}
\entry{backward-delete-char (Rubout)}{110}{\code {backward-delete-char (Rubout)}}
\entry{forward-backward-delete-char ()}{110}{\code {forward-backward-delete-char ()}}
\entry{quoted-insert (C-q or C-v)}{110}{\code {quoted-insert (C-q or C-v)}}
\entry{self-insert (a, b, A, 1, !, ...{})}{110}{\code {self-insert (a, b, A, 1, !, \dots {})}}
\entry{transpose-chars (C-t)}{110}{\code {transpose-chars (C-t)}}
\entry{transpose-words (M-t)}{110}{\code {transpose-words (M-t)}}
\entry{upcase-word (M-u)}{110}{\code {upcase-word (M-u)}}
\entry{downcase-word (M-l)}{110}{\code {downcase-word (M-l)}}
\entry{capitalize-word (M-c)}{111}{\code {capitalize-word (M-c)}}
\entry{overwrite-mode ()}{111}{\code {overwrite-mode ()}}
\entry{kill-line (C-k)}{111}{\code {kill-line (C-k)}}
\entry{backward-kill-line (C-x Rubout)}{111}{\code {backward-kill-line (C-x Rubout)}}
\entry{unix-line-discard (C-u)}{111}{\code {unix-line-discard (C-u)}}
\entry{kill-whole-line ()}{111}{\code {kill-whole-line ()}}
\entry{kill-word (M-d)}{111}{\code {kill-word (M-d)}}
\entry{backward-kill-word (M-DEL)}{111}{\code {backward-kill-word (M-\key {DEL})}}
\entry{shell-kill-word ()}{111}{\code {shell-kill-word ()}}
\entry{backward-kill-word ()}{111}{\code {backward-kill-word ()}}
\entry{unix-word-rubout (C-w)}{111}{\code {unix-word-rubout (C-w)}}
\entry{unix-filename-rubout ()}{111}{\code {unix-filename-rubout ()}}
\entry{delete-horizontal-space ()}{111}{\code {delete-horizontal-space ()}}
\entry{kill-region ()}{112}{\code {kill-region ()}}
\entry{copy-region-as-kill ()}{112}{\code {copy-region-as-kill ()}}
\entry{copy-backward-word ()}{112}{\code {copy-backward-word ()}}
\entry{copy-forward-word ()}{112}{\code {copy-forward-word ()}}
\entry{yank (C-y)}{112}{\code {yank (C-y)}}
\entry{yank-pop (M-y)}{112}{\code {yank-pop (M-y)}}
\entry{digit-argument (M-0, M-1, ...{} M--)}{112}{\code {digit-argument (\kbd {M-0}, \kbd {M-1}, \dots {} \kbd {M--})}}
\entry{universal-argument ()}{112}{\code {universal-argument ()}}
\entry{complete (TAB)}{112}{\code {complete (\key {TAB})}}
\entry{possible-completions (M-?)}{112}{\code {possible-completions (M-?)}}
\entry{insert-completions (M-*)}{113}{\code {insert-completions (M-*)}}
\entry{menu-complete ()}{113}{\code {menu-complete ()}}
\entry{menu-complete-backward ()}{113}{\code {menu-complete-backward ()}}
\entry{delete-char-or-list ()}{113}{\code {delete-char-or-list ()}}
\entry{complete-filename (M-/)}{113}{\code {complete-filename (M-/)}}
\entry{possible-filename-completions (C-x /)}{113}{\code {possible-filename-completions (C-x /)}}
\entry{complete-username (M-~)}{113}{\code {complete-username (M-~)}}
\entry{possible-username-completions (C-x ~)}{113}{\code {possible-username-completions (C-x ~)}}
\entry{complete-variable (M-$)}{113}{\code {complete-variable (M-$)}}
\entry{possible-variable-completions (C-x $)}{113}{\code {possible-variable-completions (C-x $)}}
\entry{complete-hostname (M-@)}{113}{\code {complete-hostname (M-@)}}
\entry{possible-hostname-completions (C-x @)}{113}{\code {possible-hostname-completions (C-x @)}}
\entry{complete-command (M-!)}{113}{\code {complete-command (M-!)}}
\entry{possible-command-completions (C-x !)}{114}{\code {possible-command-completions (C-x !)}}
\entry{dynamic-complete-history (M-TAB)}{114}{\code {dynamic-complete-history (M-\key {TAB})}}
\entry{dabbrev-expand ()}{114}{\code {dabbrev-expand ()}}
\entry{complete-into-braces (M-{\tt \char 123})}{114}{\code {complete-into-braces (M-{\tt \char 123})}}
\entry{start-kbd-macro (C-x ()}{114}{\code {start-kbd-macro (C-x ()}}
\entry{end-kbd-macro (C-x ))}{114}{\code {end-kbd-macro (C-x ))}}
\entry{call-last-kbd-macro (C-x e)}{114}{\code {call-last-kbd-macro (C-x e)}}
\entry{re-read-init-file (C-x C-r)}{114}{\code {re-read-init-file (C-x C-r)}}
\entry{abort (C-g)}{114}{\code {abort (C-g)}}
\entry{do-uppercase-version (M-a, M-b, M-x, ...{})}{114}{\code {do-uppercase-version (M-a, M-b, M-\var {x}, \dots {})}}
\entry{prefix-meta (ESC)}{114}{\code {prefix-meta (\key {ESC})}}
\entry{undo (C-_ or C-x C-u)}{114}{\code {undo (C-_ or C-x C-u)}}
\entry{revert-line (M-r)}{115}{\code {revert-line (M-r)}}
\entry{tilde-expand (M-&)}{115}{\code {tilde-expand (M-&)}}
\entry{set-mark (C-@)}{115}{\code {set-mark (C-@)}}
\entry{exchange-point-and-mark (C-x C-x)}{115}{\code {exchange-point-and-mark (C-x C-x)}}
\entry{character-search (C-])}{115}{\code {character-search (C-])}}
\entry{character-search-backward (M-C-])}{115}{\code {character-search-backward (M-C-])}}
\entry{skip-csi-sequence ()}{115}{\code {skip-csi-sequence ()}}
\entry{insert-comment (M-#)}{115}{\code {insert-comment (M-#)}}
\entry{dump-functions ()}{115}{\code {dump-functions ()}}
\entry{dump-variables ()}{115}{\code {dump-variables ()}}
\entry{dump-macros ()}{116}{\code {dump-macros ()}}
\entry{glob-complete-word (M-g)}{116}{\code {glob-complete-word (M-g)}}
\entry{glob-expand-word (C-x *)}{116}{\code {glob-expand-word (C-x *)}}
\entry{glob-list-expansions (C-x g)}{116}{\code {glob-list-expansions (C-x g)}}
\entry{display-shell-version (C-x C-v)}{116}{\code {display-shell-version (C-x C-v)}}
\entry{shell-expand-line (M-C-e)}{116}{\code {shell-expand-line (M-C-e)}}
\entry{history-expand-line (M-^)}{116}{\code {history-expand-line (M-^)}}
\entry{magic-space ()}{116}{\code {magic-space ()}}
\entry{alias-expand-line ()}{116}{\code {alias-expand-line ()}}
\entry{history-and-alias-expand-line ()}{116}{\code {history-and-alias-expand-line ()}}
\entry{insert-last-argument (M-. or M-_)}{116}{\code {insert-last-argument (M-. or M-_)}}
\entry{operate-and-get-next (C-o)}{116}{\code {operate-and-get-next (C-o)}}
\entry{edit-and-execute-command (C-xC-e)}{116}{\code {edit-and-execute-command (C-xC-e)}}
+103 -103
View File
@@ -1,123 +1,123 @@
\initial {A}
\entry {\code {abort (C-g)}}{112}
\entry {\code {accept-line (Newline or Return)}}{107}
\entry {\code {alias-expand-line ()}}{114}
\entry {\code {abort (C-g)}}{114}
\entry {\code {accept-line (Newline or Return)}}{109}
\entry {\code {alias-expand-line ()}}{116}
\initial {B}
\entry {\code {backward-char (C-b)}}{106}
\entry {\code {backward-delete-char (Rubout)}}{108}
\entry {\code {backward-kill-line (C-x Rubout)}}{109}
\entry {\code {backward-kill-word ()}}{109}
\entry {\code {backward-kill-word (M-\key {DEL})}}{109}
\entry {\code {backward-word (M-b)}}{106}
\entry {\code {beginning-of-history (M-<)}}{107}
\entry {\code {beginning-of-line (C-a)}}{106}
\entry {\code {backward-char (C-b)}}{108}
\entry {\code {backward-delete-char (Rubout)}}{110}
\entry {\code {backward-kill-line (C-x Rubout)}}{111}
\entry {\code {backward-kill-word ()}}{111}
\entry {\code {backward-kill-word (M-\key {DEL})}}{111}
\entry {\code {backward-word (M-b)}}{108}
\entry {\code {beginning-of-history (M-<)}}{109}
\entry {\code {beginning-of-line (C-a)}}{108}
\initial {C}
\entry {\code {call-last-kbd-macro (C-x e)}}{112}
\entry {\code {capitalize-word (M-c)}}{109}
\entry {\code {character-search (C-])}}{113}
\entry {\code {character-search-backward (M-C-])}}{113}
\entry {\code {clear-screen (C-l)}}{106}
\entry {\code {complete (\key {TAB})}}{110}
\entry {\code {complete-command (M-!)}}{111}
\entry {\code {complete-filename (M-/)}}{111}
\entry {\code {complete-hostname (M-@)}}{111}
\entry {\code {complete-into-braces (M-{\tt \char 123})}}{112}
\entry {\code {complete-username (M-~)}}{111}
\entry {\code {complete-variable (M-$)}}{111}
\entry {\code {copy-backward-word ()}}{110}
\entry {\code {copy-forward-word ()}}{110}
\entry {\code {copy-region-as-kill ()}}{110}
\entry {\code {call-last-kbd-macro (C-x e)}}{114}
\entry {\code {capitalize-word (M-c)}}{111}
\entry {\code {character-search (C-])}}{115}
\entry {\code {character-search-backward (M-C-])}}{115}
\entry {\code {clear-screen (C-l)}}{108}
\entry {\code {complete (\key {TAB})}}{112}
\entry {\code {complete-command (M-!)}}{113}
\entry {\code {complete-filename (M-/)}}{113}
\entry {\code {complete-hostname (M-@)}}{113}
\entry {\code {complete-into-braces (M-{\tt \char 123})}}{114}
\entry {\code {complete-username (M-~)}}{113}
\entry {\code {complete-variable (M-$)}}{113}
\entry {\code {copy-backward-word ()}}{112}
\entry {\code {copy-forward-word ()}}{112}
\entry {\code {copy-region-as-kill ()}}{112}
\initial {D}
\entry {\code {dabbrev-expand ()}}{112}
\entry {\code {delete-char (C-d)}}{108}
\entry {\code {delete-char-or-list ()}}{111}
\entry {\code {delete-horizontal-space ()}}{109}
\entry {\code {digit-argument (\kbd {M-0}, \kbd {M-1}, \dots {} \kbd {M--})}}{110}
\entry {\code {display-shell-version (C-x C-v)}}{114}
\entry {\code {do-uppercase-version (M-a, M-b, M-\var {x}, \dots {})}}{112}
\entry {\code {downcase-word (M-l)}}{108}
\entry {\code {dump-functions ()}}{113}
\entry {\code {dump-macros ()}}{114}
\entry {\code {dump-variables ()}}{113}
\entry {\code {dynamic-complete-history (M-\key {TAB})}}{112}
\entry {\code {dabbrev-expand ()}}{114}
\entry {\code {delete-char (C-d)}}{110}
\entry {\code {delete-char-or-list ()}}{113}
\entry {\code {delete-horizontal-space ()}}{111}
\entry {\code {digit-argument (\kbd {M-0}, \kbd {M-1}, \dots {} \kbd {M--})}}{112}
\entry {\code {display-shell-version (C-x C-v)}}{116}
\entry {\code {do-uppercase-version (M-a, M-b, M-\var {x}, \dots {})}}{114}
\entry {\code {downcase-word (M-l)}}{110}
\entry {\code {dump-functions ()}}{115}
\entry {\code {dump-macros ()}}{116}
\entry {\code {dump-variables ()}}{115}
\entry {\code {dynamic-complete-history (M-\key {TAB})}}{114}
\initial {E}
\entry {\code {edit-and-execute-command (C-xC-e)}}{114}
\entry {\code {end-kbd-macro (C-x ))}}{112}
\entry {\code {end-of-history (M->)}}{107}
\entry {\code {end-of-line (C-e)}}{106}
\entry {\code {exchange-point-and-mark (C-x C-x)}}{113}
\entry {\code {edit-and-execute-command (C-xC-e)}}{116}
\entry {\code {end-kbd-macro (C-x ))}}{114}
\entry {\code {end-of-history (M->)}}{109}
\entry {\code {end-of-line (C-e)}}{108}
\entry {\code {exchange-point-and-mark (C-x C-x)}}{115}
\initial {F}
\entry {\code {forward-backward-delete-char ()}}{108}
\entry {\code {forward-char (C-f)}}{106}
\entry {\code {forward-search-history (C-s)}}{107}
\entry {\code {forward-word (M-f)}}{106}
\entry {\code {forward-backward-delete-char ()}}{110}
\entry {\code {forward-char (C-f)}}{108}
\entry {\code {forward-search-history (C-s)}}{109}
\entry {\code {forward-word (M-f)}}{108}
\initial {G}
\entry {\code {glob-complete-word (M-g)}}{114}
\entry {\code {glob-expand-word (C-x *)}}{114}
\entry {\code {glob-list-expansions (C-x g)}}{114}
\entry {\code {glob-complete-word (M-g)}}{116}
\entry {\code {glob-expand-word (C-x *)}}{116}
\entry {\code {glob-list-expansions (C-x g)}}{116}
\initial {H}
\entry {\code {history-and-alias-expand-line ()}}{114}
\entry {\code {history-expand-line (M-^)}}{114}
\entry {\code {history-search-backward ()}}{107}
\entry {\code {history-search-forward ()}}{107}
\entry {\code {history-and-alias-expand-line ()}}{116}
\entry {\code {history-expand-line (M-^)}}{116}
\entry {\code {history-search-backward ()}}{109}
\entry {\code {history-search-forward ()}}{109}
\initial {I}
\entry {\code {insert-comment (M-#)}}{113}
\entry {\code {insert-completions (M-*)}}{111}
\entry {\code {insert-last-argument (M-. or M-_)}}{114}
\entry {\code {insert-comment (M-#)}}{115}
\entry {\code {insert-completions (M-*)}}{113}
\entry {\code {insert-last-argument (M-. or M-_)}}{116}
\initial {K}
\entry {\code {kill-line (C-k)}}{109}
\entry {\code {kill-region ()}}{110}
\entry {\code {kill-whole-line ()}}{109}
\entry {\code {kill-word (M-d)}}{109}
\entry {\code {kill-line (C-k)}}{111}
\entry {\code {kill-region ()}}{112}
\entry {\code {kill-whole-line ()}}{111}
\entry {\code {kill-word (M-d)}}{111}
\initial {M}
\entry {\code {magic-space ()}}{114}
\entry {\code {menu-complete ()}}{111}
\entry {\code {menu-complete-backward ()}}{111}
\entry {\code {magic-space ()}}{116}
\entry {\code {menu-complete ()}}{113}
\entry {\code {menu-complete-backward ()}}{113}
\initial {N}
\entry {\code {next-history (C-n)}}{107}
\entry {\code {non-incremental-forward-search-history (M-n)}}{107}
\entry {\code {non-incremental-reverse-search-history (M-p)}}{107}
\entry {\code {next-history (C-n)}}{109}
\entry {\code {non-incremental-forward-search-history (M-n)}}{109}
\entry {\code {non-incremental-reverse-search-history (M-p)}}{109}
\initial {O}
\entry {\code {operate-and-get-next (C-o)}}{114}
\entry {\code {overwrite-mode ()}}{109}
\entry {\code {operate-and-get-next (C-o)}}{116}
\entry {\code {overwrite-mode ()}}{111}
\initial {P}
\entry {\code {possible-command-completions (C-x !)}}{112}
\entry {\code {possible-completions (M-?)}}{110}
\entry {\code {possible-filename-completions (C-x /)}}{111}
\entry {\code {possible-hostname-completions (C-x @)}}{111}
\entry {\code {possible-username-completions (C-x ~)}}{111}
\entry {\code {possible-variable-completions (C-x $)}}{111}
\entry {\code {prefix-meta (\key {ESC})}}{112}
\entry {\code {previous-history (C-p)}}{107}
\entry {\code {possible-command-completions (C-x !)}}{114}
\entry {\code {possible-completions (M-?)}}{112}
\entry {\code {possible-filename-completions (C-x /)}}{113}
\entry {\code {possible-hostname-completions (C-x @)}}{113}
\entry {\code {possible-username-completions (C-x ~)}}{113}
\entry {\code {possible-variable-completions (C-x $)}}{113}
\entry {\code {prefix-meta (\key {ESC})}}{114}
\entry {\code {previous-history (C-p)}}{109}
\initial {Q}
\entry {\code {quoted-insert (C-q or C-v)}}{108}
\entry {\code {quoted-insert (C-q or C-v)}}{110}
\initial {R}
\entry {\code {re-read-init-file (C-x C-r)}}{112}
\entry {\code {redraw-current-line ()}}{106}
\entry {\code {reverse-search-history (C-r)}}{107}
\entry {\code {revert-line (M-r)}}{113}
\entry {\code {re-read-init-file (C-x C-r)}}{114}
\entry {\code {redraw-current-line ()}}{108}
\entry {\code {reverse-search-history (C-r)}}{109}
\entry {\code {revert-line (M-r)}}{115}
\initial {S}
\entry {\code {self-insert (a, b, A, 1, !, \dots {})}}{108}
\entry {\code {set-mark (C-@)}}{113}
\entry {\code {shell-backward-word ()}}{106}
\entry {\code {shell-expand-line (M-C-e)}}{114}
\entry {\code {shell-forward-word ()}}{106}
\entry {\code {shell-kill-word ()}}{109}
\entry {\code {skip-csi-sequence ()}}{113}
\entry {\code {start-kbd-macro (C-x ()}}{112}
\entry {\code {self-insert (a, b, A, 1, !, \dots {})}}{110}
\entry {\code {set-mark (C-@)}}{115}
\entry {\code {shell-backward-word ()}}{108}
\entry {\code {shell-expand-line (M-C-e)}}{116}
\entry {\code {shell-forward-word ()}}{108}
\entry {\code {shell-kill-word ()}}{111}
\entry {\code {skip-csi-sequence ()}}{115}
\entry {\code {start-kbd-macro (C-x ()}}{114}
\initial {T}
\entry {\code {tilde-expand (M-&)}}{113}
\entry {\code {transpose-chars (C-t)}}{108}
\entry {\code {transpose-words (M-t)}}{108}
\entry {\code {tilde-expand (M-&)}}{115}
\entry {\code {transpose-chars (C-t)}}{110}
\entry {\code {transpose-words (M-t)}}{110}
\initial {U}
\entry {\code {undo (C-_ or C-x C-u)}}{112}
\entry {\code {universal-argument ()}}{110}
\entry {\code {unix-filename-rubout ()}}{109}
\entry {\code {unix-line-discard (C-u)}}{109}
\entry {\code {unix-word-rubout (C-w)}}{109}
\entry {\code {upcase-word (M-u)}}{108}
\entry {\code {undo (C-_ or C-x C-u)}}{114}
\entry {\code {universal-argument ()}}{112}
\entry {\code {unix-filename-rubout ()}}{111}
\entry {\code {unix-line-discard (C-u)}}{111}
\entry {\code {unix-word-rubout (C-w)}}{111}
\entry {\code {upcase-word (M-u)}}{110}
\initial {Y}
\entry {\code {yank (C-y)}}{110}
\entry {\code {yank-last-arg (M-. or M-_)}}{108}
\entry {\code {yank-nth-arg (M-C-y)}}{107}
\entry {\code {yank-pop (M-y)}}{110}
\entry {\code {yank (C-y)}}{112}
\entry {\code {yank-last-arg (M-. or M-_)}}{110}
\entry {\code {yank-nth-arg (M-C-y)}}{109}
\entry {\code {yank-pop (M-y)}}{112}
+2585 -2415
View File
File diff suppressed because it is too large Load Diff
+414 -274
View File
@@ -2,9 +2,9 @@ This is bashref.info, produced by makeinfo version 4.13 from
/Users/chet/src/bash/src/doc/bashref.texi.
This text is a brief description of the features that are present in
the Bash shell (version 4.1, 17 April 2010).
the Bash shell (version 4.1, 30 May 2010).
This is Edition 4.1, last updated 17 April 2010, of `The GNU Bash
This is Edition 4.1, last updated 30 May 2010, of `The GNU Bash
Reference Manual', for `Bash', Version 4.1.
Copyright (C) 1988-2010 Free Software Foundation, Inc.
@@ -38,9 +38,9 @@ Bash Features
*************
This text is a brief description of the features that are present in
the Bash shell (version 4.1, 17 April 2010).
the Bash shell (version 4.1, 30 May 2010).
This is Edition 4.1, last updated 17 April 2010, of `The GNU Bash
This is Edition 4.1, last updated 30 May 2010, of `The GNU Bash
Reference Manual', for `Bash', Version 4.1.
Bash contains features that appear in other popular shells, and some
@@ -477,6 +477,14 @@ decoded as follows:
the eight-bit character whose value is the hexadecimal value HH
(one or two hex digits)
`\uHHHH'
the Unicode (ISO/IEC 10646) character whose value is the
hexadecimal value HHHH (one to four hex digits)
`\UHHHHHHHH'
the Unicode (ISO/IEC 10646) character whose value is the
hexadecimal value HHHHHHHH (one to eight hex digits)
`\cX'
a control-X character
@@ -539,6 +547,7 @@ construct, or in some other grouping.
* Lists:: How to execute commands sequentially.
* Compound Commands:: Shell commands for control flow.
* Coprocesses:: Two-way communication between commands.
* GNU Parallel:: Running commands in parallel.

File: bashref.info, Node: Simple Commands, Next: Pipelines, Up: Shell Commands
@@ -589,6 +598,12 @@ The use of `time' as a reserved word permits the timing of shell
builtins, shell functions, and pipelines. An external `time' command
cannot time these easily.
When the shell is in POSIX mode (*note Bash POSIX Mode::), `time'
may be followed by a newline. In this case, the shell displays the
total user and system time consumed by the shell and its children. The
`TIMEFORMAT' variable may be used to specify the format of the time
information.
If the pipeline is not executed asynchronously (*note Lists::), the
shell waits for all commands in the pipeline to complete.
@@ -948,7 +963,7 @@ they are not separated from the LIST by whitespace.
LIST.

File: bashref.info, Node: Coprocesses, Prev: Compound Commands, Up: Shell Commands
File: bashref.info, Node: Coprocesses, Next: GNU Parallel, Prev: Compound Commands, Up: Shell Commands
3.2.5 Coprocesses
-----------------
@@ -983,6 +998,65 @@ command may be used to wait for the coprocess to terminate.
The return status of a coprocess is the exit status of COMMAND.

File: bashref.info, Node: GNU Parallel, Prev: Coprocesses, Up: Shell Commands
3.2.6 GNU Parallel
------------------
GNU Parallel, as its name suggests, can be used to build and run
commands in parallel. You may run the same command with different
arguments, whether they are filenames, usernames, hostnames, or lines
read from files.
For a complete description, refer to the GNU Parallel documentation.
A few examples should provide a brief introduction to its use.
For example, it is easy to prefix each line in a text file with a
specified string:
cat file | parallel -k echo prefix_string
The `-k' option is required to preserve the lines' order.
Similarly, you can append a specified string to each line in a text
file:
cat file | parallel -k echo {} append_string
You can use Parallel to move files from the current directory when
the number of files is too large to process with one `mv' invocation:
ls | parallel mv {} destdir
As you can see, the {} is replaced with each line read from standard
input. This will run as many `mv' commands as there are files in the
current directory. You can emulate a parallel `xargs' by adding the
`-X' option:
ls | parallel -X mv {} destdir
GNU Parallel can replace certain common idioms that operate on lines
read from a file (in this case, filenames):
for x in $(cat list); do
do-something1 $x config-$x
do-something2 < $x
done | process-output
with a more compact syntax reminiscent of lambdas:
cat list | parallel "do-something1 {} config-{} ; do-something2 < {}" | process-output
Parallel provides a built-in mechanism to remove filename
extensions, which lends itself to batch file transformations or
renaming:
ls *.gz | parallel -j+0 "zcat {} | bzip2 >{.}.bz2 && rm {}"
This will recompress all files in the current directory with names
ending in .gz using bzip2, running one job per CPU (-j+0) in parallel.
If a command generates output, you may want to preserve the input
order in the output. For instance, the following command
{ echo foss.org.my ; echo debian.org; echo freenetproject.org; } | parallel traceroute
will display as output the traceroute invocation that finishes
first. Using the `-k' option, as we saw above
{ echo foss.org.my ; echo debian.org; echo freenetproject.org; } | parallel -k traceroute
will ensure that the output of `traceroute foss.org.my' is displayed
first.

File: bashref.info, Node: Shell Functions, Next: Shell Parameters, Prev: Shell Commands, Up: Basic Shell Features
@@ -1043,6 +1117,10 @@ is not inherited unless the `-o errtrace' shell option has been enabled.
*Note Bourne Shell Builtins::, for the description of the `trap'
builtin.
The `FUNCNEST' variable, if set to a numeric value greater than 0,
defines a maximum function nesting level. Function invocations that
exceed the limit cause the entire command to abort.
If the builtin command `return' is executed in a function, the
function completes and execution resumes with the next command after
the function call. Any command associated with the `RETURN' trap is
@@ -2945,9 +3023,14 @@ POSIX standard.
the function name and attributes are printed. If the `extdebug'
shell option is enabled using `shopt' (*note The Shopt Builtin::),
the source file name and line number where the function is defined
are displayed as well. `-F' implies `-f'. The following options
can be used to restrict output to variables with the specified
attributes or to give variables attributes:
are displayed as well. `-F' implies `-f'.
The `-g' option forces variables to be created or modified at the
global scope, even when \fBdeclare\fP is executed in a shell
function. It is ignored in all other cases.
The following options can be used to restrict output to variables
with the specified attributes or to give variables attributes:
`-a'
Each NAME is an indexed array variable (*note Arrays::).
@@ -2990,8 +3073,8 @@ POSIX standard.
exceptions that `+a' may not be used to destroy an array variable
and `+r' will not remove the readonly attribute. When used in a
function, `declare' makes each NAME local, as with the `local'
command. If a variable name is followed by =VALUE, the value of
the variable is set to VALUE.
command, unless the `-g' option is used. If a variable name is
followed by =VALUE, the value of the variable is set to VALUE.
The return status is zero unless an invalid option is encountered,
an attempt is made to define a function using `-f foo=bar', an
@@ -3055,6 +3138,14 @@ POSIX standard.
the eight-bit character whose value is the hexadecimal value
HH (one or two hex digits)
`\uHHHH'
the Unicode (ISO/IEC 10646) character whose value is the
hexadecimal value HHHH (one to four hex digits)
`\UHHHHHHHH'
the Unicode (ISO/IEC 10646) character whose value is the
hexadecimal value HHHHHHHH (one to eight hex digits)
`enable'
enable [-a] [-dnps] [-f FILENAME] [NAME ...]
Enable and disable builtin shell commands. Disabling a builtin
@@ -3159,9 +3250,9 @@ POSIX standard.
If `-C' is specified without `-c', the default quantum is 5000.
When CALLBACK is evaluated, it is supplied the index of the next
array element to be assigned as an additional argument. CALLBACK
is evaluated after the line is read but before the array element
is assigned.
array element to be assigned and the line to be assigned to that
element as additional arguments. CALLBACK is evaluated after the
line is read but before the array element is assigned.
If not supplied with an explicit origin, `mapfile' will clear ARRAY
before assigning to it.
@@ -3173,27 +3264,42 @@ POSIX standard.
`printf'
printf [-v VAR] FORMAT [ARGUMENTS]
Write the formatted ARGUMENTS to the standard output under the
control of the FORMAT. The FORMAT is a character string which
contains three types of objects: plain characters, which are
simply copied to standard output, character escape sequences,
which are converted and copied to the standard output, and format
specifications, each of which causes printing of the next
successive ARGUMENT. In addition to the standard `printf(1)'
formats, `%b' causes `printf' to expand backslash escape sequences
in the corresponding ARGUMENT, (except that `\c' terminates
output, backslashes in `\'', `\"', and `\?' are not removed, and
octal escapes beginning with `\0' may contain up to four digits),
and `%q' causes `printf' to output the corresponding ARGUMENT in a
format that can be reused as shell input.
control of the FORMAT. The `-v' option causes the output to be
assigned to the variable VAR rather than being printed to the
standard output.
The FORMAT is a character string which contains three types of
objects: plain characters, which are simply copied to standard
output, character escape sequences, which are converted and copied
to the standard output, and format specifications, each of which
causes printing of the next successive ARGUMENT. In addition to
the standard `printf(1)' formats, `printf' interprets the
following extensions:
`%b'
causes `printf' to expand backslash escape sequences in the
corresponding ARGUMENT, (except that `\c' terminates output,
backslashes in `\'', `\"', and `\?' are not removed, and
octal escapes beginning with `\0' may contain up to four
digits).
`%q'
causes `printf' to output the corresponding ARGUMENT in a
format that can be reused as shell input.
`%(DATEFMT)T'
causes `printf' to output the date-time string resulting from
using DATEFMT as a format string for `strftime'(3). The
corresponding ARGUMENT is an integer representing the number
of seconds since the epoch. Two special argument values may
be used: -1 represents the current time, and -2 represents
the time the shell was invoked.
Arguments to non-string format specifiers are treated as C
language constants, except that a leading plus or minus sign is
allowed, and if the leading character is a single or double quote,
the value is the ASCII value of the following character.
The `-v' option causes the output to be assigned to the variable
VAR rather than being printed to the standard output.
The FORMAT is reused as necessary to consume all of the ARGUMENTS.
If the FORMAT requires more ARGUMENTS than are supplied, the extra
format specifications behave as if a zero value or null string, as
@@ -4328,6 +4434,11 @@ Variables::).
effect and return an error status. If `FUNCNAME' is unset, it
loses its special properties, even if it is subsequently reset.
`FUNCNEST'
If set to a numeric value greater than 0, defines a maximum
function nesting level. Function invocations that exceed this
nesting level will cause the current command to abort.
`GLOBIGNORE'
A colon-separated list of patterns defining the set of filenames to
be ignored by filename expansion. If a filename matched by a
@@ -5170,10 +5281,14 @@ link itself.
does not.
`-o OPTNAME'
True if shell option OPTNAME is enabled. The list of options
True if the shell option OPTNAME is enabled. The list of options
appears in the description of the `-o' option to the `set' builtin
(*note The Set Builtin::).
`-v VARNAME'
True if the shell variable VARNAME is set (has been assigned a
value).
`-z STRING'
True if the length of STRING is zero.
@@ -5761,116 +5876,131 @@ startup files.
13. Non-interactive shells exit if a syntax error in an arithmetic
expansion results in an invalid expression.
14. Redirection operators do not perform filename expansion on the word
14. Non-interactive shells exit if there is a syntax error in a script
read with the `.' or `source' builtins, or in a string processed by
the `eval' builtin.
15. Redirection operators do not perform filename expansion on the word
in the redirection unless the shell is interactive.
15. Redirection operators do not perform word splitting on the word in
16. Redirection operators do not perform word splitting on the word in
the redirection.
16. Function names must be valid shell `name's. That is, they may not
17. Function names must be valid shell `name's. That is, they may not
contain characters other than letters, digits, and underscores, and
may not start with a digit. Declaring a function with an invalid
name causes a fatal syntax error in non-interactive shells.
17. POSIX special builtins are found before shell functions during
18. POSIX special builtins are found before shell functions during
command lookup.
18. If a POSIX special builtin returns an error status, a
19. The `time' reserved word may be used by itself as a command. When
used in this way, it displays timing statistics for the shell and
its completed children. The `TIMEFORMAT' variable controls the
format of the timing information.
20. When parsing and expanding a ${...} expansion that appears within
double quotes, single quotes are no longer special and cannot be
used to quote a closing brace or other special character, unless
the operator is one of those defined to perform pattern removal.
In this case, they do not have to appear as matched pairs.
21. If a POSIX special builtin returns an error status, a
non-interactive shell exits. The fatal errors are those listed in
the POSIX standard, and include things like passing incorrect
options, redirection errors, variable assignment errors for
assignments preceding the command name, and so on.
19. If `CDPATH' is set, the `cd' builtin will not implicitly append
22. If `CDPATH' is set, the `cd' builtin will not implicitly append
the current directory to it. This means that `cd' will fail if no
valid directory name can be constructed from any of the entries in
`$CDPATH', even if the a directory with the same name as the name
given as an argument to `cd' exists in the current directory.
20. A non-interactive shell exits with an error status if a variable
23. A non-interactive shell exits with an error status if a variable
assignment error occurs when no command name follows the assignment
statements. A variable assignment error occurs, for example, when
trying to assign a value to a readonly variable.
21. A non-interactive shell exits with an error status if the iteration
24. A non-interactive shell exits with an error status if the iteration
variable in a `for' statement or the selection variable in a
`select' statement is a readonly variable.
22. Process substitution is not available.
25. Process substitution is not available.
23. Assignment statements preceding POSIX special builtins persist in
26. Assignment statements preceding POSIX special builtins persist in
the shell environment after the builtin completes.
24. Assignment statements preceding shell function calls persist in the
27. Assignment statements preceding shell function calls persist in the
shell environment after the function returns, as if a POSIX
special builtin command had been executed.
25. The `export' and `readonly' builtin commands display their output
28. The `export' and `readonly' builtin commands display their output
in the format required by POSIX.
26. The `trap' builtin displays signal names without the leading `SIG'.
29. The `trap' builtin displays signal names without the leading `SIG'.
27. The `trap' builtin doesn't check the first argument for a possible
30. The `trap' builtin doesn't check the first argument for a possible
signal specification and revert the signal handling to the original
disposition if it is, unless that argument consists solely of
digits and is a valid signal number. If users want to reset the
handler for a given signal to the original disposition, they
should use `-' as the first argument.
28. The `.' and `source' builtins do not search the current directory
31. The `.' and `source' builtins do not search the current directory
for the filename argument if it is not found by searching `PATH'.
29. Subshells spawned to execute command substitutions inherit the
32. 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.
30. Alias expansion is always enabled, even in non-interactive shells.
33. Alias expansion is always enabled, even in non-interactive shells.
31. When the `alias' builtin displays alias definitions, it does not
34. When the `alias' builtin displays alias definitions, it does not
display them with a leading `alias ' unless the `-p' option is
supplied.
32. When the `set' builtin is invoked without options, it does not
35. When the `set' builtin is invoked without options, it does not
display shell function names and definitions.
33. When the `set' builtin is invoked without options, it displays
36. When the `set' builtin is invoked without options, it displays
variable values without quotes, unless they contain shell
metacharacters, even if the result contains nonprinting characters.
34. When the `cd' builtin is invoked in LOGICAL mode, and the pathname
37. When the `cd' builtin is invoked in LOGICAL mode, and the pathname
constructed from `$PWD' and the directory name supplied as an
argument does not refer to an existing directory, `cd' will fail
instead of falling back to PHYSICAL mode.
35. When the `pwd' builtin is supplied the `-P' option, it resets
38. When the `pwd' builtin is supplied the `-P' option, it resets
`$PWD' to a pathname containing no symlinks.
36. The `pwd' builtin verifies that the value it prints is the same as
39. The `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 `-P' option.
37. When listing the history, the `fc' builtin does not include an
40. When listing the history, the `fc' builtin does not include an
indication of whether or not a history entry has been modified.
38. The default editor used by `fc' is `ed'.
41. The default editor used by `fc' is `ed'.
39. The `type' and `command' builtins will not report a non-executable
42. The `type' and `command' builtins will not report a non-executable
file as having been found, though the shell will attempt to
execute such a file if it is the only so-named file found in
`$PATH'.
40. The `vi' editing mode will invoke the `vi' editor directly when
43. The `vi' editing mode will invoke the `vi' editor directly when
the `v' command is run, instead of checking `$VISUAL' and
`$EDITOR'.
41. When the `xpg_echo' option is enabled, Bash does not attempt to
44. When the `xpg_echo' option is enabled, Bash does not attempt to
interpret any arguments to `echo' as options. Each argument is
displayed, after escape characters are converted.
42. The `ulimit' builtin uses a block size of 512 bytes for the `-c'
45. The `ulimit' builtin uses a block size of 512 bytes for the `-c'
and `-f' options.
43. The arrival of `SIGCHLD' when a trap is set on `SIGCHLD' does not
46. The arrival of `SIGCHLD' when a trap is set on `SIGCHLD' does not
interrupt the `wait' builtin and cause it to return immediately.
The trap command is run once for each child that exits.
@@ -6507,6 +6637,12 @@ Variable Settings
completion in a case-insensitive fashion. The default value
is `off'.
`completion-map-case'
If set to `on', and COMPLETION-IGNORE-CASE is enabled,
Readline treats hyphens (`-') and underscores (`_') as
equivalent when performing case-insensitive filename matching
and completion.
`completion-prefix-display-length'
The length in characters of the common prefix of a list of
possible completions that is displayed without modification.
@@ -9714,8 +9850,8 @@ D.1 Index of Shell Builtin Commands
(line 7)
* disown: Job Control Builtins.
(line 83)
* echo: Bash Builtins. (line 221)
* enable: Bash Builtins. (line 273)
* echo: Bash Builtins. (line 226)
* enable: Bash Builtins. (line 286)
* eval: Bourne Shell Builtins.
(line 63)
* exec: Bourne Shell Builtins.
@@ -9732,26 +9868,26 @@ D.1 Index of Shell Builtin Commands
(line 103)
* hash: Bourne Shell Builtins.
(line 145)
* help: Bash Builtins. (line 301)
* help: Bash Builtins. (line 314)
* history: Bash History Builtins.
(line 39)
* jobs: Job Control Builtins.
(line 25)
* kill: Job Control Builtins.
(line 57)
* let: Bash Builtins. (line 321)
* local: Bash Builtins. (line 328)
* logout: Bash Builtins. (line 338)
* mapfile: Bash Builtins. (line 342)
* let: Bash Builtins. (line 334)
* local: Bash Builtins. (line 341)
* logout: Bash Builtins. (line 351)
* mapfile: Bash Builtins. (line 355)
* popd: Directory Stack Builtins.
(line 37)
* printf: Bash Builtins. (line 388)
* printf: Bash Builtins. (line 401)
* pushd: Directory Stack Builtins.
(line 58)
* pwd: Bourne Shell Builtins.
(line 164)
* read: Bash Builtins. (line 418)
* readarray: Bash Builtins. (line 498)
* read: Bash Builtins. (line 446)
* readarray: Bash Builtins. (line 526)
* readonly: Bourne Shell Builtins.
(line 173)
* return: Bourne Shell Builtins.
@@ -9760,7 +9896,7 @@ D.1 Index of Shell Builtin Commands
* shift: Bourne Shell Builtins.
(line 202)
* shopt: The Shopt Builtin. (line 9)
* source: Bash Builtins. (line 506)
* source: Bash Builtins. (line 534)
* suspend: Job Control Builtins.
(line 94)
* test: Bourne Shell Builtins.
@@ -9769,12 +9905,12 @@ D.1 Index of Shell Builtin Commands
(line 282)
* trap: Bourne Shell Builtins.
(line 287)
* type: Bash Builtins. (line 510)
* typeset: Bash Builtins. (line 541)
* ulimit: Bash Builtins. (line 547)
* type: Bash Builtins. (line 538)
* typeset: Bash Builtins. (line 569)
* ulimit: Bash Builtins. (line 575)
* umask: Bourne Shell Builtins.
(line 333)
* unalias: Bash Builtins. (line 636)
* unalias: Bash Builtins. (line 664)
* unset: Bourne Shell Builtins.
(line 350)
* wait: Job Control Builtins.
@@ -9879,133 +10015,136 @@ D.3 Parameter and Variable Index
(line 55)
* completion-ignore-case: Readline Init File Syntax.
(line 62)
* completion-prefix-display-length: Readline Init File Syntax.
* completion-map-case: Readline Init File Syntax.
(line 67)
* completion-prefix-display-length: Readline Init File Syntax.
(line 73)
* completion-query-items: Readline Init File Syntax.
(line 74)
(line 80)
* COMPREPLY: Bash Variables. (line 193)
* convert-meta: Readline Init File Syntax.
(line 84)
(line 90)
* COPROC: Bash Variables. (line 198)
* DIRSTACK: Bash Variables. (line 202)
* disable-completion: Readline Init File Syntax.
(line 90)
(line 96)
* editing-mode: Readline Init File Syntax.
(line 95)
(line 101)
* EMACS: Bash Variables. (line 212)
* enable-keypad: Readline Init File Syntax.
(line 106)
(line 112)
* ENV: Bash Variables. (line 217)
* EUID: Bash Variables. (line 221)
* expand-tilde: Readline Init File Syntax.
(line 117)
(line 123)
* FCEDIT: Bash Variables. (line 225)
* FIGNORE: Bash Variables. (line 229)
* FUNCNAME: Bash Variables. (line 235)
* GLOBIGNORE: Bash Variables. (line 244)
* GROUPS: Bash Variables. (line 250)
* histchars: Bash Variables. (line 256)
* HISTCMD: Bash Variables. (line 271)
* HISTCONTROL: Bash Variables. (line 276)
* HISTFILE: Bash Variables. (line 292)
* HISTFILESIZE: Bash Variables. (line 296)
* HISTIGNORE: Bash Variables. (line 304)
* FUNCNEST: Bash Variables. (line 244)
* GLOBIGNORE: Bash Variables. (line 249)
* GROUPS: Bash Variables. (line 255)
* histchars: Bash Variables. (line 261)
* HISTCMD: Bash Variables. (line 276)
* HISTCONTROL: Bash Variables. (line 281)
* HISTFILE: Bash Variables. (line 297)
* HISTFILESIZE: Bash Variables. (line 301)
* HISTIGNORE: Bash Variables. (line 309)
* history-preserve-point: Readline Init File Syntax.
(line 121)
* history-size: Readline Init File Syntax.
(line 127)
* HISTSIZE: Bash Variables. (line 323)
* HISTTIMEFORMAT: Bash Variables. (line 327)
* history-size: Readline Init File Syntax.
(line 133)
* HISTSIZE: Bash Variables. (line 328)
* HISTTIMEFORMAT: Bash Variables. (line 332)
* HOME: Bourne Shell Variables.
(line 13)
* horizontal-scroll-mode: Readline Init File Syntax.
(line 132)
* HOSTFILE: Bash Variables. (line 336)
* HOSTNAME: Bash Variables. (line 347)
* HOSTTYPE: Bash Variables. (line 350)
(line 138)
* HOSTFILE: Bash Variables. (line 341)
* HOSTNAME: Bash Variables. (line 352)
* HOSTTYPE: Bash Variables. (line 355)
* IFS: Bourne Shell Variables.
(line 18)
* IGNOREEOF: Bash Variables. (line 353)
* IGNOREEOF: Bash Variables. (line 358)
* input-meta: Readline Init File Syntax.
(line 139)
* INPUTRC: Bash Variables. (line 363)
(line 145)
* INPUTRC: Bash Variables. (line 368)
* isearch-terminators: Readline Init File Syntax.
(line 146)
(line 152)
* keymap: Readline Init File Syntax.
(line 153)
* LANG: Bash Variables. (line 367)
* LC_ALL: Bash Variables. (line 371)
* LC_COLLATE: Bash Variables. (line 375)
* LC_CTYPE: Bash Variables. (line 382)
(line 159)
* LANG: Bash Variables. (line 372)
* LC_ALL: Bash Variables. (line 376)
* LC_COLLATE: Bash Variables. (line 380)
* LC_CTYPE: Bash Variables. (line 387)
* LC_MESSAGES <1>: Locale Translation. (line 11)
* LC_MESSAGES: Bash Variables. (line 387)
* LC_NUMERIC: Bash Variables. (line 391)
* LINENO: Bash Variables. (line 395)
* LINES: Bash Variables. (line 399)
* MACHTYPE: Bash Variables. (line 404)
* LC_MESSAGES: Bash Variables. (line 392)
* LC_NUMERIC: Bash Variables. (line 396)
* LINENO: Bash Variables. (line 400)
* LINES: Bash Variables. (line 404)
* MACHTYPE: Bash Variables. (line 409)
* MAIL: Bourne Shell Variables.
(line 22)
* MAILCHECK: Bash Variables. (line 408)
* MAILCHECK: Bash Variables. (line 413)
* MAILPATH: Bourne Shell Variables.
(line 27)
* MAPFILE: Bash Variables. (line 416)
* MAPFILE: Bash Variables. (line 421)
* mark-modified-lines: Readline Init File Syntax.
(line 166)
(line 172)
* mark-symlinked-directories: Readline Init File Syntax.
(line 171)
(line 177)
* match-hidden-files: Readline Init File Syntax.
(line 176)
(line 182)
* meta-flag: Readline Init File Syntax.
(line 139)
* OLDPWD: Bash Variables. (line 420)
(line 145)
* OLDPWD: Bash Variables. (line 425)
* OPTARG: Bourne Shell Variables.
(line 34)
* OPTERR: Bash Variables. (line 423)
* OPTERR: Bash Variables. (line 428)
* OPTIND: Bourne Shell Variables.
(line 38)
* OSTYPE: Bash Variables. (line 427)
* OSTYPE: Bash Variables. (line 432)
* output-meta: Readline Init File Syntax.
(line 183)
(line 189)
* page-completions: Readline Init File Syntax.
(line 188)
(line 194)
* PATH: Bourne Shell Variables.
(line 42)
* PIPESTATUS: Bash Variables. (line 430)
* POSIXLY_CORRECT: Bash Variables. (line 435)
* PPID: Bash Variables. (line 444)
* PROMPT_COMMAND: Bash Variables. (line 448)
* PROMPT_DIRTRIM: Bash Variables. (line 452)
* PIPESTATUS: Bash Variables. (line 435)
* POSIXLY_CORRECT: Bash Variables. (line 440)
* PPID: Bash Variables. (line 449)
* PROMPT_COMMAND: Bash Variables. (line 453)
* PROMPT_DIRTRIM: Bash Variables. (line 457)
* PS1: Bourne Shell Variables.
(line 48)
* PS2: Bourne Shell Variables.
(line 53)
* PS3: Bash Variables. (line 458)
* PS4: Bash Variables. (line 463)
* PWD: Bash Variables. (line 469)
* RANDOM: Bash Variables. (line 472)
* READLINE_LINE: Bash Variables. (line 477)
* READLINE_POINT: Bash Variables. (line 481)
* REPLY: Bash Variables. (line 485)
* PS3: Bash Variables. (line 463)
* PS4: Bash Variables. (line 468)
* PWD: Bash Variables. (line 474)
* RANDOM: Bash Variables. (line 477)
* READLINE_LINE: Bash Variables. (line 482)
* READLINE_POINT: Bash Variables. (line 486)
* REPLY: Bash Variables. (line 490)
* revert-all-at-newline: Readline Init File Syntax.
(line 198)
* SECONDS: Bash Variables. (line 488)
* SHELL: Bash Variables. (line 494)
* SHELLOPTS: Bash Variables. (line 499)
* SHLVL: Bash Variables. (line 508)
* show-all-if-ambiguous: Readline Init File Syntax.
(line 204)
* show-all-if-unmodified: Readline Init File Syntax.
* SECONDS: Bash Variables. (line 493)
* SHELL: Bash Variables. (line 499)
* SHELLOPTS: Bash Variables. (line 504)
* SHLVL: Bash Variables. (line 513)
* show-all-if-ambiguous: Readline Init File Syntax.
(line 210)
* show-all-if-unmodified: Readline Init File Syntax.
(line 216)
* skip-completed-text: Readline Init File Syntax.
(line 219)
(line 225)
* TEXTDOMAIN: Locale Translation. (line 11)
* TEXTDOMAINDIR: Locale Translation. (line 11)
* TIMEFORMAT: Bash Variables. (line 513)
* TMOUT: Bash Variables. (line 551)
* TMPDIR: Bash Variables. (line 563)
* UID: Bash Variables. (line 567)
* TIMEFORMAT: Bash Variables. (line 518)
* TMOUT: Bash Variables. (line 556)
* TMPDIR: Bash Variables. (line 568)
* UID: Bash Variables. (line 572)
* visible-stats: Readline Init File Syntax.
(line 232)
(line 238)

File: bashref.info, Node: Function Index, Next: Concept Index, Prev: Variable Index, Up: Indexes
@@ -10274,132 +10413,133 @@ D.5 Concept Index

Tag Table:
Node: Top1340
Node: Introduction3173
Node: What is Bash?3401
Node: What is a shell?4514
Node: Definitions7054
Node: Basic Shell Features9972
Node: Shell Syntax11191
Node: Shell Operation12221
Node: Quoting13515
Node: Escape Character14818
Node: Single Quotes15303
Node: Double Quotes15651
Node: ANSI-C Quoting16776
Node: Locale Translation17761
Node: Comments18657
Node: Shell Commands19275
Node: Simple Commands20099
Node: Pipelines20730
Node: Lists22986
Node: Compound Commands24715
Node: Looping Constructs25519
Node: Conditional Constructs27974
Node: Command Grouping36087
Node: Coprocesses37566
Node: Shell Functions39210
Node: Shell Parameters43764
Node: Positional Parameters46180
Node: Special Parameters47080
Node: Shell Expansions50044
Node: Brace Expansion51969
Node: Tilde Expansion54724
Node: Shell Parameter Expansion57075
Node: Command Substitution65976
Node: Arithmetic Expansion67309
Node: Process Substitution68159
Node: Word Splitting69209
Node: Filename Expansion70832
Node: Pattern Matching72971
Node: Quote Removal76610
Node: Redirections76905
Node: Executing Commands85430
Node: Simple Command Expansion86100
Node: Command Search and Execution88030
Node: Command Execution Environment90367
Node: Environment93353
Node: Exit Status95013
Node: Signals96634
Node: Shell Scripts98602
Node: Shell Builtin Commands101120
Node: Bourne Shell Builtins103148
Node: Bash Builtins120616
Node: Modifying Shell Behavior145759
Node: The Set Builtin146104
Node: The Shopt Builtin155628
Node: Special Builtins166962
Node: Shell Variables167941
Node: Bourne Shell Variables168381
Node: Bash Variables170362
Node: Bash Features194495
Node: Invoking Bash195378
Node: Bash Startup Files201142
Node: Interactive Shells206154
Node: What is an Interactive Shell?206564
Node: Is this Shell Interactive?207213
Node: Interactive Shell Behavior208028
Node: Bash Conditional Expressions211308
Node: Shell Arithmetic214957
Node: Aliases217716
Node: Arrays220288
Node: The Directory Stack224246
Node: Directory Stack Builtins224960
Node: Printing a Prompt227852
Node: The Restricted Shell230604
Node: Bash POSIX Mode232436
Node: Job Control240493
Node: Job Control Basics240953
Node: Job Control Builtins245670
Node: Job Control Variables250034
Node: Command Line Editing251192
Node: Introduction and Notation252759
Node: Readline Interaction254381
Node: Readline Bare Essentials255572
Node: Readline Movement Commands257361
Node: Readline Killing Commands258326
Node: Readline Arguments260246
Node: Searching261290
Node: Readline Init File263476
Node: Readline Init File Syntax264623
Node: Conditional Init Constructs279472
Node: Sample Init File282005
Node: Bindable Readline Commands285122
Node: Commands For Moving286329
Node: Commands For History287473
Node: Commands For Text290628
Node: Commands For Killing293301
Node: Numeric Arguments295752
Node: Commands For Completion296891
Node: Keyboard Macros301083
Node: Miscellaneous Commands301654
Node: Readline vi Mode307460
Node: Programmable Completion308367
Node: Programmable Completion Builtins315577
Node: Using History Interactively324713
Node: Bash History Facilities325397
Node: Bash History Builtins328311
Node: History Interaction332168
Node: Event Designators334873
Node: Word Designators335888
Node: Modifiers337527
Node: Installing Bash338931
Node: Basic Installation340068
Node: Compilers and Options342760
Node: Compiling For Multiple Architectures343501
Node: Installation Names345165
Node: Specifying the System Type345983
Node: Sharing Defaults346699
Node: Operation Controls347372
Node: Optional Features348330
Node: Reporting Bugs357889
Node: Major Differences From The Bourne Shell359090
Node: GNU Free Documentation License375777
Node: Indexes400973
Node: Builtin Index401427
Node: Reserved Word Index408254
Node: Variable Index410702
Node: Function Index423442
Node: Concept Index430451
Node: Top1336
Node: Introduction3165
Node: What is Bash?3393
Node: What is a shell?4506
Node: Definitions7046
Node: Basic Shell Features9964
Node: Shell Syntax11183
Node: Shell Operation12213
Node: Quoting13507
Node: Escape Character14810
Node: Single Quotes15295
Node: Double Quotes15643
Node: ANSI-C Quoting16768
Node: Locale Translation18012
Node: Comments18908
Node: Shell Commands19526
Node: Simple Commands20398
Node: Pipelines21029
Node: Lists23576
Node: Compound Commands25305
Node: Looping Constructs26109
Node: Conditional Constructs28564
Node: Command Grouping36677
Node: Coprocesses38156
Node: GNU Parallel39821
Node: Shell Functions42289
Node: Shell Parameters47035
Node: Positional Parameters49451
Node: Special Parameters50351
Node: Shell Expansions53315
Node: Brace Expansion55240
Node: Tilde Expansion57995
Node: Shell Parameter Expansion60346
Node: Command Substitution69247
Node: Arithmetic Expansion70580
Node: Process Substitution71430
Node: Word Splitting72480
Node: Filename Expansion74103
Node: Pattern Matching76242
Node: Quote Removal79881
Node: Redirections80176
Node: Executing Commands88701
Node: Simple Command Expansion89371
Node: Command Search and Execution91301
Node: Command Execution Environment93638
Node: Environment96624
Node: Exit Status98284
Node: Signals99905
Node: Shell Scripts101873
Node: Shell Builtin Commands104391
Node: Bourne Shell Builtins106419
Node: Bash Builtins123887
Node: Modifying Shell Behavior150092
Node: The Set Builtin150437
Node: The Shopt Builtin159961
Node: Special Builtins171295
Node: Shell Variables172274
Node: Bourne Shell Variables172714
Node: Bash Variables174695
Node: Bash Features199033
Node: Invoking Bash199916
Node: Bash Startup Files205680
Node: Interactive Shells210692
Node: What is an Interactive Shell?211102
Node: Is this Shell Interactive?211751
Node: Interactive Shell Behavior212566
Node: Bash Conditional Expressions215846
Node: Shell Arithmetic219594
Node: Aliases222353
Node: Arrays224925
Node: The Directory Stack228883
Node: Directory Stack Builtins229597
Node: Printing a Prompt232489
Node: The Restricted Shell235241
Node: Bash POSIX Mode237073
Node: Job Control245899
Node: Job Control Basics246359
Node: Job Control Builtins251076
Node: Job Control Variables255440
Node: Command Line Editing256598
Node: Introduction and Notation258165
Node: Readline Interaction259787
Node: Readline Bare Essentials260978
Node: Readline Movement Commands262767
Node: Readline Killing Commands263732
Node: Readline Arguments265652
Node: Searching266696
Node: Readline Init File268882
Node: Readline Init File Syntax270029
Node: Conditional Init Constructs285133
Node: Sample Init File287666
Node: Bindable Readline Commands290783
Node: Commands For Moving291990
Node: Commands For History293134
Node: Commands For Text296289
Node: Commands For Killing298962
Node: Numeric Arguments301413
Node: Commands For Completion302552
Node: Keyboard Macros306744
Node: Miscellaneous Commands307315
Node: Readline vi Mode313121
Node: Programmable Completion314028
Node: Programmable Completion Builtins321238
Node: Using History Interactively330374
Node: Bash History Facilities331058
Node: Bash History Builtins333972
Node: History Interaction337829
Node: Event Designators340534
Node: Word Designators341549
Node: Modifiers343188
Node: Installing Bash344592
Node: Basic Installation345729
Node: Compilers and Options348421
Node: Compiling For Multiple Architectures349162
Node: Installation Names350826
Node: Specifying the System Type351644
Node: Sharing Defaults352360
Node: Operation Controls353033
Node: Optional Features353991
Node: Reporting Bugs363550
Node: Major Differences From The Bourne Shell364751
Node: GNU Free Documentation License381438
Node: Indexes406634
Node: Builtin Index407088
Node: Reserved Word Index413915
Node: Variable Index416363
Node: Function Index429317
Node: Concept Index436326

End Tag Table
+82 -43
View File
@@ -1,4 +1,4 @@
This is TeX, Version 3.141592 (Web2C 7.5.4) (format=tex 2008.12.11) 20 MAY 2010 16:33
This is TeX, Version 3.141592 (Web2C 7.5.4) (format=tex 2008.12.11) 1 JUN 2010 14:16
**/Users/chet/src/bash/src/doc/bashref.texi
(/Users/chet/src/bash/src/doc/bashref.texi (./texinfo.tex
Loading texinfo [version 2009-01-18.17]:
@@ -177,8 +177,8 @@ and turning on texinfo input format.) (./bashref.aux)
\openout0 = `bashref.toc'.
Chapter 2
[1] [2] [3] Chapter 3 [4] [5] [6] [7] [8] [9]
Overfull \hbox (43.33539pt too wide) in paragraph at lines 856--856
[1] [2] [3] Chapter 3 [4] [5] [6] [7] [8] [9] [10]
Overfull \hbox (43.33539pt too wide) in paragraph at lines 869--869
[]@texttt case @textttsl word @texttt in [ [(] @textttsl pat-tern @texttt [| @
textttsl pat-tern@texttt ][]) @textttsl command-list @texttt ;;][] esac[][]
@@ -190,10 +190,49 @@ textttsl pat-tern@texttt ][]) @textttsl command-list @texttt ;;][] esac[][]
.@texttt s
.etc.
[10] [11] [12] [13] [14] [15] [16] [17] [18] [19] [20] [21] [22] [23] [24]
[25] [26] [27] [28] [29] [30] [31] [32] Chapter 4 [33] [34] [35] [36] [37]
[38] [39] [40] [41]
Underfull \hbox (badness 5231) in paragraph at lines 3302--3315
[11] [12] [13] [14]
Overfull \hbox (89.6747pt too wide) in paragraph at lines 1191--1191
[]@texttt cat list | parallel "do-something1 {} config-{} ; do-something2 < {}
" | process-output[]
@hbox(7.60416+2.43333)x433.62
.@glue(@leftskip) 28.90755
.@hbox(0.0+0.0)x0.0
.@texttt c
.@texttt a
.@texttt t
.etc.
Overfull \hbox (89.6747pt too wide) in paragraph at lines 1206--1206
[]@texttt { echo foss.org.my ; echo debian.org; echo freenetproject.org; } | p
arallel traceroute[]
@hbox(7.60416+2.43333)x433.62
.@glue(@leftskip) 28.90755
.@hbox(0.0+0.0)x0.0
.@texttt {
.@penalty 10000
.@glue 5.74869
.etc.
Overfull \hbox (106.92076pt too wide) in paragraph at lines 1212--1212
[]@texttt { echo foss.org.my ; echo debian.org; echo freenetproject.org; } | p
arallel -k traceroute[]
@hbox(7.60416+2.43333)x433.62
.@glue(@leftskip) 28.90755
.@hbox(0.0+0.0)x0.0
.@texttt {
.@penalty 10000
.@glue 5.74869
.etc.
[15] [16] [17] [18] [19] [20] [21] [22] [23] [24] [25] [26] [27] [28] [29]
[30] [31] [32] [33] [34] Chapter 4 [35] [36] [37] [38] [39] [40] [41] [42]
[43]
Underfull \hbox (badness 5231) in paragraph at lines 3395--3408
@texttt emacs-meta[]@textrm , @texttt emacs-ctlx[]@textrm , @texttt vi[]@textr
m , @texttt vi-move[]@textrm , @texttt vi-command[]@textrm , and
@@ -205,8 +244,8 @@ m , @texttt vi-move[]@textrm , @texttt vi-command[]@textrm , and
.@texttt c
.etc.
[42] [43] [44] [45] [46]
Overfull \hbox (172.34125pt too wide) in paragraph at lines 3733--3733
[44] [45] [46] [47] [48] [49]
Overfull \hbox (172.34125pt too wide) in paragraph at lines 3852--3852
[]@texttt read [-ers] [-a @textttsl aname@texttt ] [-d @textttsl de-lim@texttt
] [-i @textttsl text@texttt ] [-n @textttsl nchars@texttt ] [-N @textttsl ncha
rs@texttt ] [-p @textttsl prompt@texttt ] [-t @textttsl time-
@@ -219,9 +258,9 @@ rs@texttt ] [-p @textttsl prompt@texttt ] [-t @textttsl time-
.@texttt a
.etc.
[47] [48] [49] [50] [51] [52] [53] [54] [55] [56] [57] [58] Chapter 5 [59]
[60] [61] [62] [63] [64] [65] [66] [67] [68] [69] Chapter 6 [70]
Overfull \hbox (51.96864pt too wide) in paragraph at lines 5321--5321
[50] [51] [52] [53] [54] [55] [56] [57] [58] [59] [60] [61] Chapter 5 [62]
[63] [64] [65] [66] [67] [68] [69] [70] [71] Chapter 6 [72]
Overfull \hbox (51.96864pt too wide) in paragraph at lines 5445--5445
[]@texttt bash [long-opt] [-ir] [-abefhkmnptuvxdBCDHP] [-o @textttsl op-tion@t
exttt ] [-O @textttsl shopt_option@texttt ] [@textttsl ar-
@@ -234,7 +273,7 @@ exttt ] [-O @textttsl shopt_option@texttt ] [@textttsl ar-
.etc.
Overfull \hbox (76.23077pt too wide) in paragraph at lines 5322--5322
Overfull \hbox (76.23077pt too wide) in paragraph at lines 5446--5446
[]@texttt bash [long-opt] [-abefhkmnptuvxdBCDHP] [-o @textttsl op-tion@texttt
] [-O @textttsl shopt_option@texttt ] -c @textttsl string @texttt [@textttsl ar
-
@@ -248,7 +287,7 @@ Overfull \hbox (76.23077pt too wide) in paragraph at lines 5322--5322
.etc.
Overfull \hbox (34.72258pt too wide) in paragraph at lines 5323--5323
Overfull \hbox (34.72258pt too wide) in paragraph at lines 5447--5447
[]@texttt bash [long-opt] -s [-abefhkmnptuvxdBCDHP] [-o @textttsl op-tion@text
tt ] [-O @textttsl shopt_option@texttt ] [@textttsl ar-
@@ -260,8 +299,8 @@ tt ] [-O @textttsl shopt_option@texttt ] [@textttsl ar-
.@texttt s
.etc.
[71] [72]
Underfull \hbox (badness 2245) in paragraph at lines 5496--5498
[73] [74]
Underfull \hbox (badness 2245) in paragraph at lines 5620--5622
[]@textrm When a lo-gin shell ex-its, Bash reads and ex-e-cutes com-mands from
the file
@@ -273,8 +312,8 @@ the file
.@textrm n
.etc.
[73] [74] [75] [76] [77] [78] [79] [80] [81] [82] [83] [84] [85]
Underfull \hbox (badness 2521) in paragraph at lines 6644--6647
[75] [76] [77] [78] [79] [80] [81] [82] [83] [84] [85] [86] [87] [88]
Underfull \hbox (badness 2521) in paragraph at lines 6789--6792
@textrm `@texttt --enable-strict-posix-default[]@textrm '[] to @texttt configur
e[] @textrm when build-ing (see Sec-tion 10.8
@@ -286,10 +325,10 @@ e[] @textrm when build-ing (see Sec-tion 10.8
.@texttt n
.etc.
Chapter 7 [86] [87] [88] [89] [90] [91]
(/Users/chet/src/bash/src/lib/readline/doc/rluser.texi Chapter 8 [92] [93]
[94] [95] [96] [97] [98]
Underfull \hbox (badness 5231) in paragraph at lines 545--561
Chapter 7 [89] [90] [91] [92] [93]
(/Users/chet/src/bash/src/lib/readline/doc/rluser.texi Chapter 8 [94] [95]
[96] [97] [98] [99] [100]
Underfull \hbox (badness 5231) in paragraph at lines 551--567
@texttt emacs-meta[]@textrm , @texttt emacs-ctlx[]@textrm , @texttt vi[]@textr
m , @texttt vi-move[]@textrm , @texttt vi-command[]@textrm , and
@@ -301,8 +340,8 @@ m , @texttt vi-move[]@textrm , @texttt vi-command[]@textrm , and
.@texttt c
.etc.
[99] [100] [101] [102] [103]
Overfull \hbox (26.43913pt too wide) in paragraph at lines 882--882
[101] [102] [103] [104] [105]
Overfull \hbox (26.43913pt too wide) in paragraph at lines 888--888
[]@texttt Meta-Control-h: backward-kill-word Text after the function name is i
gnored[]
@@ -314,9 +353,9 @@ gnored[]
.@texttt t
.etc.
[104] [105] [106] [107] [108] [109] [110] [111] [112] [113] [114] [115]
[116]
Overfull \hbox (12.05716pt too wide) in paragraph at lines 1803--1803
[106] [107] [108] [109] [110] [111] [112] [113] [114] [115] [116] [117]
[118]
Overfull \hbox (12.05716pt too wide) in paragraph at lines 1809--1809
[]@texttt complete [-abcdefgjksuv] [-o @textttsl comp-option@texttt ] [-DE] [-
A @textttsl ac-tion@texttt ] [-
@@ -328,8 +367,8 @@ A @textttsl ac-tion@texttt ] [-
.@texttt m
.etc.
[117] [118]
Underfull \hbox (badness 2753) in paragraph at lines 1913--1916
[119] [120]
Underfull \hbox (badness 2753) in paragraph at lines 1919--1922
@texttt hostname[]@textrm Hostnames, as taken from the file spec-i-fied by
@hbox(7.60416+2.12917)x433.62, glue set 3.02202
@@ -340,9 +379,9 @@ Underfull \hbox (badness 2753) in paragraph at lines 1913--1916
.@texttt o
.etc.
[119]) (/Users/chet/src/bash/src/lib/readline/doc/hsuser.texi Chapter 9
[120] [121] [122] [123] [124]) Chapter 10 [125] [126] [127] [128] [129]
Underfull \hbox (badness 2772) in paragraph at lines 7245--7249
[121]) (/Users/chet/src/bash/src/lib/readline/doc/hsuser.texi Chapter 9
[122] [123] [124] [125] [126]) Chapter 10 [127] [128] [129] [130] [131]
Underfull \hbox (badness 2772) in paragraph at lines 7390--7394
[]@textrm Enable sup-port for large files (@texttt http://www.sas.com/standard
s/large_
@@ -354,18 +393,18 @@ s/large_
.@textrm a
.etc.
[130] [131] [132] Appendix A [133] [134] Appendix B [135] [136] [137] [138]
[139] [140] [141] Appendix C [142] (./fdl.texi [143] [144] [145] [146] [147]
[148] [149]) Appendix D [150] (./bashref.bts) [151] (./bashref.rws)
(./bashref.vrs [152] [153]) (./bashref.fns [154] [155]) (./bashref.cps [156])
[157] [158] )
[132] [133] [134] Appendix A [135] [136] Appendix B [137] [138] [139] [140]
[141] [142] [143] Appendix C [144] (./fdl.texi [145] [146] [147] [148] [149]
[150] [151]) Appendix D [152] (./bashref.bts) [153] (./bashref.rws)
(./bashref.vrs [154] [155]) (./bashref.fns [156] [157]) (./bashref.cps [158])
[159] [160] )
Here is how much of TeX's memory you used:
2078 strings out of 97980
28503 string characters out of 1221004
65573 words of memory out of 1500000
2894 multiletter control sequences out of 10000+50000
2081 strings out of 97980
28558 string characters out of 1221004
65603 words of memory out of 1500000
2897 multiletter control sequences out of 10000+50000
32127 words of font info for 112 fonts, out of 1200000 for 2000
51 hyphenation exceptions out of 8191
16i,6n,14p,315b,699s stack positions out of 5000i,500n,6000p,200000b,5000s
16i,6n,14p,315b,702s stack positions out of 5000i,500n,6000p,200000b,5000s
Output written on bashref.dvi (164 pages, 668052 bytes).
Output written on bashref.dvi (166 pages, 675816 bytes).
BIN
View File
Binary file not shown.
+5655 -5500
View File
File diff suppressed because it is too large Load Diff
+10 -10
View File
@@ -1,21 +1,21 @@
\entry{time}{8}{\code {time}}
\entry{!}{8}{\code {!}}
\entry{until}{9}{\code {until}}
\entry{do}{9}{\code {do}}
\entry{done}{9}{\code {done}}
\entry{while}{9}{\code {while}}
\entry{until}{10}{\code {until}}
\entry{do}{10}{\code {do}}
\entry{done}{10}{\code {done}}
\entry{while}{10}{\code {while}}
\entry{for}{10}{\code {for}}
\entry{if}{10}{\code {if}}
\entry{then}{10}{\code {then}}
\entry{else}{10}{\code {else}}
\entry{elif}{10}{\code {elif}}
\entry{fi}{10}{\code {fi}}
\entry{case}{10}{\code {case}}
\entry{in}{10}{\code {in}}
\entry{esac}{10}{\code {esac}}
\entry{case}{11}{\code {case}}
\entry{in}{11}{\code {in}}
\entry{esac}{11}{\code {esac}}
\entry{select}{11}{\code {select}}
\entry{[[}{12}{\code {[[}}
\entry{]]}{12}{\code {]]}}
\entry{{\tt \char 123}}{13}{\code {{\tt \char 123}}}
\entry{{\tt \char 125}}{13}{\code {{\tt \char 125}}}
\entry{function}{14}{\code {function}}
\entry{{\tt \char 123}}{14}{\code {{\tt \char 123}}}
\entry{{\tt \char 125}}{14}{\code {{\tt \char 125}}}
\entry{function}{15}{\code {function}}
+10 -10
View File
@@ -5,31 +5,31 @@
\initial {]}
\entry {\code {]]}}{12}
\initial {{\tt \char 123}}
\entry {\code {{\tt \char 123}}}{13}
\entry {\code {{\tt \char 123}}}{14}
\initial {{\tt \char 125}}
\entry {\code {{\tt \char 125}}}{13}
\entry {\code {{\tt \char 125}}}{14}
\initial {C}
\entry {\code {case}}{10}
\entry {\code {case}}{11}
\initial {D}
\entry {\code {do}}{9}
\entry {\code {done}}{9}
\entry {\code {do}}{10}
\entry {\code {done}}{10}
\initial {E}
\entry {\code {elif}}{10}
\entry {\code {else}}{10}
\entry {\code {esac}}{10}
\entry {\code {esac}}{11}
\initial {F}
\entry {\code {fi}}{10}
\entry {\code {for}}{10}
\entry {\code {function}}{14}
\entry {\code {function}}{15}
\initial {I}
\entry {\code {if}}{10}
\entry {\code {in}}{10}
\entry {\code {in}}{11}
\initial {S}
\entry {\code {select}}{11}
\initial {T}
\entry {\code {then}}{10}
\entry {\code {time}}{8}
\initial {U}
\entry {\code {until}}{9}
\entry {\code {until}}{10}
\initial {W}
\entry {\code {while}}{9}
\entry {\code {while}}{10}
+10 -4
View File
@@ -1154,7 +1154,7 @@ string:
@example
cat file | parallel -k echo prefix_string
@end example
@noindent
The @option{-k} option is required to preserve the lines' order.
Similarly, you can append a specified string to each line in a text file:
@@ -1185,6 +1185,7 @@ from a file (in this case, filenames):
done | process-output
@end example
@noindent
with a more compact syntax reminiscent of lambdas:
@example
cat list | parallel "do-something1 @{@} config-@{@} ; do-something2 < @{@}" | process-output
@@ -1195,7 +1196,7 @@ lends itself to batch file transformations or renaming:
@example
ls *.gz | parallel -j+0 "zcat @{@} | bzip2 >@{.@}.bz2 && rm @{@}"
@end example
@noindent
This will recompress all files in the current directory with names ending
in .gz using bzip2, running one job per CPU (-j+0) in parallel.
@@ -1204,12 +1205,13 @@ the output. For instance, the following command
@example
@{ echo foss.org.my ; echo debian.org; echo freenetproject.org; @} | parallel traceroute
@end example
@noindent
will display as output the traceroute invocation that finishes first. Using
the @option{-k} option, as we saw above
@example
@{ echo foss.org.my ; echo debian.org; echo freenetproject.org; @} | parallel -k traceroute
@end example
@noindent
will ensure that the output of @code{traceroute foss.org.my} is displayed first.
@node Shell Functions
@@ -2929,7 +2931,7 @@ The return status is zero unless @var{n} is not greater than or equal to 1.
@item cd
@btindex cd
@example
cd [-L|-P] [@var{directory}]
cd [-L|[-P [-e]]] [@var{directory}]
@end example
Change the current working directory to @var{directory}.
If @var{directory} is not given, the value of the @env{HOME} shell
@@ -2939,6 +2941,10 @@ If @var{directory} begins with a slash, @env{CDPATH} is not used.
The @option{-P} option means to not follow symbolic links; symbolic
links are followed by default or with the @option{-L} option.
If the @option{-e} option is supplied with @option{-P}
and the current working directory cannot be successfully determined
after a successful directory change, @code{cd} will return an unsuccessful
status.
If @var{directory} is @samp{-}, it is equivalent to @env{$OLDPWD}.
If a non-empty directory name from @env{CDPATH} is used, or if
+26 -11
View File
@@ -1154,7 +1154,7 @@ string:
@example
cat file | parallel -k echo prefix_string
@end example
@noindent
The @option{-k} option is required to preserve the lines' order.
Similarly, you can append a specified string to each line in a text file:
@@ -1185,6 +1185,7 @@ from a file (in this case, filenames):
done | process-output
@end example
@noindent
with a more compact syntax reminiscent of lambdas:
@example
cat list | parallel "do-something1 @{@} config-@{@} ; do-something2 < @{@}" | process-output
@@ -1195,7 +1196,7 @@ lends itself to batch file transformations or renaming:
@example
ls *.gz | parallel -j+0 "zcat @{@} | bzip2 >@{.@}.bz2 && rm @{@}"
@end example
@noindent
This will recompress all files in the current directory with names ending
in .gz using bzip2, running one job per CPU (-j+0) in parallel.
@@ -1204,12 +1205,13 @@ the output. For instance, the following command
@example
@{ echo foss.org.my ; echo debian.org; echo freenetproject.org; @} | parallel traceroute
@end example
@noindent
will display as output the traceroute invocation that finishes first. Using
the @option{-k} option, as we saw above
@example
@{ echo foss.org.my ; echo debian.org; echo freenetproject.org; @} | parallel -k traceroute
@end example
@noindent
will ensure that the output of @code{traceroute foss.org.my} is displayed first.
@node Shell Functions
@@ -3803,28 +3805,41 @@ printf [-v @var{var}] @var{format} [@var{arguments}]
@end example
Write the formatted @var{arguments} to the standard output under the
control of the @var{format}.
The @option{-v} option causes the output to be assigned to the variable
@var{var} rather than being printed to the standard output.
The @var{format} is a character string which contains three types of objects:
plain characters, which are simply copied to standard output, character
escape sequences, which are converted and copied to the standard output, and
format specifications, each of which causes printing of the next successive
@var{argument}.
In addition to the standard @code{printf(1)} formats, @samp{%b} causes
@code{printf} to expand backslash escape sequences in the corresponding
@var{argument},
In addition to the standard @code{printf(1)} formats, @code{printf}
interprets the following extensions:
@table @code
@item %b
causes @code{printf} to expand backslash escape sequences in the
corresponding @var{argument},
(except that @samp{\c} terminates output, backslashes in
@samp{\'}, @samp{\"}, and @samp{\?} are not removed, and octal escapes
beginning with @samp{\0} may contain up to four digits),
and @samp{%q} causes @code{printf} to output the
beginning with @samp{\0} may contain up to four digits).
@item %q
causes @code{printf} to output the
corresponding @var{argument} in a format that can be reused as shell input.
@item %(@var{datefmt})T
causes @code{printf} to output the date-time string resulting from using
@var{datefmt} as a format string for @code{strftime}(3). The corresponding
@var{argument} is an integer representing the number of seconds since the
epoch. Two special argument values may be used: -1 represents the current
time, and -2 represents the time the shell was invoked.
@end table
@noindent
Arguments to non-string format specifiers are treated as C language constants,
except that a leading plus or minus sign is allowed, and if the leading
character is a single or double quote, the value is the ASCII value of
the following character.
The @option{-v} option causes the output to be assigned to the variable
@var{var} rather than being printed to the standard output.
The @var{format} is reused as necessary to consume all of the @var{arguments}.
If the @var{format} requires more @var{arguments} than are supplied, the
extra format specifications behave as if a zero value or null string, as
+118 -117
View File
@@ -12,126 +12,127 @@
@numsubsubsecentry{ANSI-C Quoting}{3.1.2.4}{ANSI-C Quoting}{6}
@numsubsubsecentry{Locale-Specific Translation}{3.1.2.5}{Locale Translation}{7}
@numsubsecentry{Comments}{3.1.3}{Comments}{7}
@numsecentry{Shell Commands}{3.2}{Shell Commands}{7}
@numsecentry{Shell Commands}{3.2}{Shell Commands}{8}
@numsubsecentry{Simple Commands}{3.2.1}{Simple Commands}{8}
@numsubsecentry{Pipelines}{3.2.2}{Pipelines}{8}
@numsubsecentry{Lists of Commands}{3.2.3}{Lists}{8}
@numsubsecentry{Lists of Commands}{3.2.3}{Lists}{9}
@numsubsecentry{Compound Commands}{3.2.4}{Compound Commands}{9}
@numsubsubsecentry{Looping Constructs}{3.2.4.1}{Looping Constructs}{9}
@numsubsubsecentry{Looping Constructs}{3.2.4.1}{Looping Constructs}{10}
@numsubsubsecentry{Conditional Constructs}{3.2.4.2}{Conditional Constructs}{10}
@numsubsubsecentry{Grouping Commands}{3.2.4.3}{Command Grouping}{13}
@numsubsecentry{Coprocesses}{3.2.5}{Coprocesses}{14}
@numsecentry{Shell Functions}{3.3}{Shell Functions}{14}
@numsecentry{Shell Parameters}{3.4}{Shell Parameters}{15}
@numsubsecentry{Positional Parameters}{3.4.1}{Positional Parameters}{16}
@numsubsecentry{Special Parameters}{3.4.2}{Special Parameters}{16}
@numsecentry{Shell Expansions}{3.5}{Shell Expansions}{17}
@numsubsecentry{Brace Expansion}{3.5.1}{Brace Expansion}{18}
@numsubsecentry{Tilde Expansion}{3.5.2}{Tilde Expansion}{19}
@numsubsecentry{Shell Parameter Expansion}{3.5.3}{Shell Parameter Expansion}{19}
@numsubsecentry{Command Substitution}{3.5.4}{Command Substitution}{22}
@numsubsecentry{Arithmetic Expansion}{3.5.5}{Arithmetic Expansion}{23}
@numsubsecentry{Process Substitution}{3.5.6}{Process Substitution}{23}
@numsubsecentry{Word Splitting}{3.5.7}{Word Splitting}{23}
@numsubsecentry{Filename Expansion}{3.5.8}{Filename Expansion}{24}
@numsubsubsecentry{Pattern Matching}{3.5.8.1}{Pattern Matching}{24}
@numsubsecentry{Quote Removal}{3.5.9}{Quote Removal}{25}
@numsecentry{Redirections}{3.6}{Redirections}{26}
@numsubsecentry{Redirecting Input}{3.6.1}{}{27}
@numsubsecentry{Redirecting Output}{3.6.2}{}{27}
@numsubsecentry{Appending Redirected Output}{3.6.3}{}{27}
@numsubsecentry{Redirecting Standard Output and Standard Error}{3.6.4}{}{27}
@numsubsecentry{Appending Standard Output and Standard Error}{3.6.5}{}{28}
@numsubsecentry{Here Documents}{3.6.6}{}{28}
@numsubsecentry{Here Strings}{3.6.7}{}{28}
@numsubsecentry{Duplicating File Descriptors}{3.6.8}{}{28}
@numsubsecentry{Moving File Descriptors}{3.6.9}{}{29}
@numsubsecentry{Opening File Descriptors for Reading and Writing}{3.6.10}{}{29}
@numsecentry{Executing Commands}{3.7}{Executing Commands}{29}
@numsubsecentry{Simple Command Expansion}{3.7.1}{Simple Command Expansion}{29}
@numsubsecentry{Command Search and Execution}{3.7.2}{Command Search and Execution}{30}
@numsubsecentry{Command Execution Environment}{3.7.3}{Command Execution Environment}{30}
@numsubsecentry{Environment}{3.7.4}{Environment}{31}
@numsubsecentry{Exit Status}{3.7.5}{Exit Status}{32}
@numsubsecentry{Signals}{3.7.6}{Signals}{32}
@numsecentry{Shell Scripts}{3.8}{Shell Scripts}{33}
@numchapentry{Shell Builtin Commands}{4}{Shell Builtin Commands}{35}
@numsecentry{Bourne Shell Builtins}{4.1}{Bourne Shell Builtins}{35}
@numsecentry{Bash Builtin Commands}{4.2}{Bash Builtins}{41}
@numsecentry{Modifying Shell Behavior}{4.3}{Modifying Shell Behavior}{51}
@numsubsecentry{The Set Builtin}{4.3.1}{The Set Builtin}{51}
@numsubsecentry{The Shopt Builtin}{4.3.2}{The Shopt Builtin}{55}
@numsecentry{Special Builtins}{4.4}{Special Builtins}{59}
@numchapentry{Shell Variables}{5}{Shell Variables}{61}
@numsecentry{Bourne Shell Variables}{5.1}{Bourne Shell Variables}{61}
@numsecentry{Bash Variables}{5.2}{Bash Variables}{61}
@numchapentry{Bash Features}{6}{Bash Features}{71}
@numsecentry{Invoking Bash}{6.1}{Invoking Bash}{71}
@numsecentry{Bash Startup Files}{6.2}{Bash Startup Files}{73}
@numsecentry{Interactive Shells}{6.3}{Interactive Shells}{74}
@numsubsecentry{What is an Interactive Shell?}{6.3.1}{What is an Interactive Shell?}{75}
@numsubsecentry{Is this Shell Interactive?}{6.3.2}{Is this Shell Interactive?}{75}
@numsubsecentry{Interactive Shell Behavior}{6.3.3}{Interactive Shell Behavior}{75}
@numsecentry{Bash Conditional Expressions}{6.4}{Bash Conditional Expressions}{76}
@numsecentry{Shell Arithmetic}{6.5}{Shell Arithmetic}{78}
@numsecentry{Aliases}{6.6}{Aliases}{79}
@numsecentry{Arrays}{6.7}{Arrays}{80}
@numsecentry{The Directory Stack}{6.8}{The Directory Stack}{81}
@numsubsecentry{Directory Stack Builtins}{6.8.1}{Directory Stack Builtins}{81}
@numsecentry{Controlling the Prompt}{6.9}{Printing a Prompt}{82}
@numsecentry{The Restricted Shell}{6.10}{The Restricted Shell}{84}
@numsecentry{Bash POSIX Mode}{6.11}{Bash POSIX Mode}{84}
@numchapentry{Job Control}{7}{Job Control}{89}
@numsecentry{Job Control Basics}{7.1}{Job Control Basics}{89}
@numsecentry{Job Control Builtins}{7.2}{Job Control Builtins}{90}
@numsecentry{Job Control Variables}{7.3}{Job Control Variables}{92}
@numchapentry{Command Line Editing}{8}{Command Line Editing}{93}
@numsecentry{Introduction to Line Editing}{8.1}{Introduction and Notation}{93}
@numsecentry{Readline Interaction}{8.2}{Readline Interaction}{93}
@numsubsecentry{Readline Bare Essentials}{8.2.1}{Readline Bare Essentials}{94}
@numsubsecentry{Readline Movement Commands}{8.2.2}{Readline Movement Commands}{94}
@numsubsecentry{Readline Killing Commands}{8.2.3}{Readline Killing Commands}{95}
@numsubsecentry{Readline Arguments}{8.2.4}{Readline Arguments}{95}
@numsubsecentry{Searching for Commands in the History}{8.2.5}{Searching}{95}
@numsecentry{Readline Init File}{8.3}{Readline Init File}{96}
@numsubsecentry{Readline Init File Syntax}{8.3.1}{Readline Init File Syntax}{96}
@numsubsecentry{Conditional Init Constructs}{8.3.2}{Conditional Init Constructs}{102}
@numsubsecentry{Sample Init File}{8.3.3}{Sample Init File}{103}
@numsecentry{Bindable Readline Commands}{8.4}{Bindable Readline Commands}{106}
@numsubsecentry{Commands For Moving}{8.4.1}{Commands For Moving}{106}
@numsubsecentry{Commands For Manipulating The History}{8.4.2}{Commands For History}{107}
@numsubsecentry{Commands For Changing Text}{8.4.3}{Commands For Text}{108}
@numsubsecentry{Killing And Yanking}{8.4.4}{Commands For Killing}{109}
@numsubsecentry{Specifying Numeric Arguments}{8.4.5}{Numeric Arguments}{110}
@numsubsecentry{Letting Readline Type For You}{8.4.6}{Commands For Completion}{110}
@numsubsecentry{Keyboard Macros}{8.4.7}{Keyboard Macros}{112}
@numsubsecentry{Some Miscellaneous Commands}{8.4.8}{Miscellaneous Commands}{112}
@numsecentry{Readline vi Mode}{8.5}{Readline vi Mode}{115}
@numsecentry{Programmable Completion}{8.6}{Programmable Completion}{115}
@numsecentry{Programmable Completion Builtins}{8.7}{Programmable Completion Builtins}{117}
@numchapentry{Using History Interactively}{9}{Using History Interactively}{121}
@numsecentry{Bash History Facilities}{9.1}{Bash History Facilities}{121}
@numsecentry{Bash History Builtins}{9.2}{Bash History Builtins}{121}
@numsecentry{History Expansion}{9.3}{History Interaction}{123}
@numsubsecentry{Event Designators}{9.3.1}{Event Designators}{123}
@numsubsecentry{Word Designators}{9.3.2}{Word Designators}{124}
@numsubsecentry{Modifiers}{9.3.3}{Modifiers}{125}
@numchapentry{Installing Bash}{10}{Installing Bash}{127}
@numsecentry{Basic Installation}{10.1}{Basic Installation}{127}
@numsecentry{Compilers and Options}{10.2}{Compilers and Options}{128}
@numsecentry{Compiling For Multiple Architectures}{10.3}{Compiling For Multiple Architectures}{128}
@numsecentry{Installation Names}{10.4}{Installation Names}{128}
@numsecentry{Specifying the System Type}{10.5}{Specifying the System Type}{128}
@numsecentry{Sharing Defaults}{10.6}{Sharing Defaults}{129}
@numsecentry{Operation Controls}{10.7}{Operation Controls}{129}
@numsecentry{Optional Features}{10.8}{Optional Features}{129}
@appentry{Reporting Bugs}{A}{Reporting Bugs}{135}
@appentry{Major Differences From The Bourne Shell}{B}{Major Differences From The Bourne Shell}{137}
@appsecentry{Implementation Differences From The SVR4.2 Shell}{B.1}{}{141}
@appentry{GNU Free Documentation License}{C}{GNU Free Documentation License}{143}
@appentry{Indexes}{D}{Indexes}{151}
@appsecentry{Index of Shell Builtin Commands}{D.1}{Builtin Index}{151}
@appsecentry{Index of Shell Reserved Words}{D.2}{Reserved Word Index}{152}
@appsecentry{Parameter and Variable Index}{D.3}{Variable Index}{152}
@appsecentry{Function Index}{D.4}{Function Index}{154}
@appsecentry{Concept Index}{D.5}{Concept Index}{156}
@numsubsecentry{GNU Parallel}{3.2.6}{GNU Parallel}{14}
@numsecentry{Shell Functions}{3.3}{Shell Functions}{15}
@numsecentry{Shell Parameters}{3.4}{Shell Parameters}{17}
@numsubsecentry{Positional Parameters}{3.4.1}{Positional Parameters}{17}
@numsubsecentry{Special Parameters}{3.4.2}{Special Parameters}{18}
@numsecentry{Shell Expansions}{3.5}{Shell Expansions}{18}
@numsubsecentry{Brace Expansion}{3.5.1}{Brace Expansion}{19}
@numsubsecentry{Tilde Expansion}{3.5.2}{Tilde Expansion}{20}
@numsubsecentry{Shell Parameter Expansion}{3.5.3}{Shell Parameter Expansion}{21}
@numsubsecentry{Command Substitution}{3.5.4}{Command Substitution}{24}
@numsubsecentry{Arithmetic Expansion}{3.5.5}{Arithmetic Expansion}{24}
@numsubsecentry{Process Substitution}{3.5.6}{Process Substitution}{24}
@numsubsecentry{Word Splitting}{3.5.7}{Word Splitting}{25}
@numsubsecentry{Filename Expansion}{3.5.8}{Filename Expansion}{25}
@numsubsubsecentry{Pattern Matching}{3.5.8.1}{Pattern Matching}{26}
@numsubsecentry{Quote Removal}{3.5.9}{Quote Removal}{27}
@numsecentry{Redirections}{3.6}{Redirections}{27}
@numsubsecentry{Redirecting Input}{3.6.1}{}{28}
@numsubsecentry{Redirecting Output}{3.6.2}{}{28}
@numsubsecentry{Appending Redirected Output}{3.6.3}{}{28}
@numsubsecentry{Redirecting Standard Output and Standard Error}{3.6.4}{}{29}
@numsubsecentry{Appending Standard Output and Standard Error}{3.6.5}{}{29}
@numsubsecentry{Here Documents}{3.6.6}{}{29}
@numsubsecentry{Here Strings}{3.6.7}{}{29}
@numsubsecentry{Duplicating File Descriptors}{3.6.8}{}{30}
@numsubsecentry{Moving File Descriptors}{3.6.9}{}{30}
@numsubsecentry{Opening File Descriptors for Reading and Writing}{3.6.10}{}{30}
@numsecentry{Executing Commands}{3.7}{Executing Commands}{30}
@numsubsecentry{Simple Command Expansion}{3.7.1}{Simple Command Expansion}{30}
@numsubsecentry{Command Search and Execution}{3.7.2}{Command Search and Execution}{31}
@numsubsecentry{Command Execution Environment}{3.7.3}{Command Execution Environment}{32}
@numsubsecentry{Environment}{3.7.4}{Environment}{33}
@numsubsecentry{Exit Status}{3.7.5}{Exit Status}{33}
@numsubsecentry{Signals}{3.7.6}{Signals}{34}
@numsecentry{Shell Scripts}{3.8}{Shell Scripts}{34}
@numchapentry{Shell Builtin Commands}{4}{Shell Builtin Commands}{37}
@numsecentry{Bourne Shell Builtins}{4.1}{Bourne Shell Builtins}{37}
@numsecentry{Bash Builtin Commands}{4.2}{Bash Builtins}{43}
@numsecentry{Modifying Shell Behavior}{4.3}{Modifying Shell Behavior}{53}
@numsubsecentry{The Set Builtin}{4.3.1}{The Set Builtin}{53}
@numsubsecentry{The Shopt Builtin}{4.3.2}{The Shopt Builtin}{57}
@numsecentry{Special Builtins}{4.4}{Special Builtins}{62}
@numchapentry{Shell Variables}{5}{Shell Variables}{63}
@numsecentry{Bourne Shell Variables}{5.1}{Bourne Shell Variables}{63}
@numsecentry{Bash Variables}{5.2}{Bash Variables}{63}
@numchapentry{Bash Features}{6}{Bash Features}{73}
@numsecentry{Invoking Bash}{6.1}{Invoking Bash}{73}
@numsecentry{Bash Startup Files}{6.2}{Bash Startup Files}{75}
@numsecentry{Interactive Shells}{6.3}{Interactive Shells}{76}
@numsubsecentry{What is an Interactive Shell?}{6.3.1}{What is an Interactive Shell?}{77}
@numsubsecentry{Is this Shell Interactive?}{6.3.2}{Is this Shell Interactive?}{77}
@numsubsecentry{Interactive Shell Behavior}{6.3.3}{Interactive Shell Behavior}{77}
@numsecentry{Bash Conditional Expressions}{6.4}{Bash Conditional Expressions}{78}
@numsecentry{Shell Arithmetic}{6.5}{Shell Arithmetic}{80}
@numsecentry{Aliases}{6.6}{Aliases}{81}
@numsecentry{Arrays}{6.7}{Arrays}{82}
@numsecentry{The Directory Stack}{6.8}{The Directory Stack}{83}
@numsubsecentry{Directory Stack Builtins}{6.8.1}{Directory Stack Builtins}{83}
@numsecentry{Controlling the Prompt}{6.9}{Printing a Prompt}{84}
@numsecentry{The Restricted Shell}{6.10}{The Restricted Shell}{86}
@numsecentry{Bash POSIX Mode}{6.11}{Bash POSIX Mode}{86}
@numchapentry{Job Control}{7}{Job Control}{91}
@numsecentry{Job Control Basics}{7.1}{Job Control Basics}{91}
@numsecentry{Job Control Builtins}{7.2}{Job Control Builtins}{92}
@numsecentry{Job Control Variables}{7.3}{Job Control Variables}{94}
@numchapentry{Command Line Editing}{8}{Command Line Editing}{95}
@numsecentry{Introduction to Line Editing}{8.1}{Introduction and Notation}{95}
@numsecentry{Readline Interaction}{8.2}{Readline Interaction}{95}
@numsubsecentry{Readline Bare Essentials}{8.2.1}{Readline Bare Essentials}{96}
@numsubsecentry{Readline Movement Commands}{8.2.2}{Readline Movement Commands}{96}
@numsubsecentry{Readline Killing Commands}{8.2.3}{Readline Killing Commands}{97}
@numsubsecentry{Readline Arguments}{8.2.4}{Readline Arguments}{97}
@numsubsecentry{Searching for Commands in the History}{8.2.5}{Searching}{97}
@numsecentry{Readline Init File}{8.3}{Readline Init File}{98}
@numsubsecentry{Readline Init File Syntax}{8.3.1}{Readline Init File Syntax}{98}
@numsubsecentry{Conditional Init Constructs}{8.3.2}{Conditional Init Constructs}{104}
@numsubsecentry{Sample Init File}{8.3.3}{Sample Init File}{105}
@numsecentry{Bindable Readline Commands}{8.4}{Bindable Readline Commands}{108}
@numsubsecentry{Commands For Moving}{8.4.1}{Commands For Moving}{108}
@numsubsecentry{Commands For Manipulating The History}{8.4.2}{Commands For History}{109}
@numsubsecentry{Commands For Changing Text}{8.4.3}{Commands For Text}{110}
@numsubsecentry{Killing And Yanking}{8.4.4}{Commands For Killing}{111}
@numsubsecentry{Specifying Numeric Arguments}{8.4.5}{Numeric Arguments}{112}
@numsubsecentry{Letting Readline Type For You}{8.4.6}{Commands For Completion}{112}
@numsubsecentry{Keyboard Macros}{8.4.7}{Keyboard Macros}{114}
@numsubsecentry{Some Miscellaneous Commands}{8.4.8}{Miscellaneous Commands}{114}
@numsecentry{Readline vi Mode}{8.5}{Readline vi Mode}{117}
@numsecentry{Programmable Completion}{8.6}{Programmable Completion}{117}
@numsecentry{Programmable Completion Builtins}{8.7}{Programmable Completion Builtins}{119}
@numchapentry{Using History Interactively}{9}{Using History Interactively}{123}
@numsecentry{Bash History Facilities}{9.1}{Bash History Facilities}{123}
@numsecentry{Bash History Builtins}{9.2}{Bash History Builtins}{123}
@numsecentry{History Expansion}{9.3}{History Interaction}{125}
@numsubsecentry{Event Designators}{9.3.1}{Event Designators}{125}
@numsubsecentry{Word Designators}{9.3.2}{Word Designators}{126}
@numsubsecentry{Modifiers}{9.3.3}{Modifiers}{127}
@numchapentry{Installing Bash}{10}{Installing Bash}{129}
@numsecentry{Basic Installation}{10.1}{Basic Installation}{129}
@numsecentry{Compilers and Options}{10.2}{Compilers and Options}{130}
@numsecentry{Compiling For Multiple Architectures}{10.3}{Compiling For Multiple Architectures}{130}
@numsecentry{Installation Names}{10.4}{Installation Names}{130}
@numsecentry{Specifying the System Type}{10.5}{Specifying the System Type}{130}
@numsecentry{Sharing Defaults}{10.6}{Sharing Defaults}{131}
@numsecentry{Operation Controls}{10.7}{Operation Controls}{131}
@numsecentry{Optional Features}{10.8}{Optional Features}{131}
@appentry{Reporting Bugs}{A}{Reporting Bugs}{137}
@appentry{Major Differences From The Bourne Shell}{B}{Major Differences From The Bourne Shell}{139}
@appsecentry{Implementation Differences From The SVR4.2 Shell}{B.1}{}{143}
@appentry{GNU Free Documentation License}{C}{GNU Free Documentation License}{145}
@appentry{Indexes}{D}{Indexes}{153}
@appsecentry{Index of Shell Builtin Commands}{D.1}{Builtin Index}{153}
@appsecentry{Index of Shell Reserved Words}{D.2}{Reserved Word Index}{154}
@appsecentry{Parameter and Variable Index}{D.3}{Variable Index}{154}
@appsecentry{Function Index}{D.4}{Function Index}{156}
@appsecentry{Concept Index}{D.5}{Concept Index}{158}
+134 -132
View File
@@ -1,135 +1,137 @@
\entry{LC_MESSAGES}{7}{\code {LC_MESSAGES}}
\entry{TEXTDOMAIN}{7}{\code {TEXTDOMAIN}}
\entry{TEXTDOMAINDIR}{7}{\code {TEXTDOMAINDIR}}
\entry{*}{16}{\code {*}}
\entry{@}{16}{\code {@}}
\entry{#}{17}{\code {#}}
\entry{?}{17}{\code {?}}
\entry{-}{17}{\code {-}}
\entry{$}{17}{\code {$}}
\entry{!}{17}{\code {!}}
\entry{0}{17}{\code {0}}
\entry{_}{17}{\code {_}}
\entry{CDPATH}{61}{\code {CDPATH}}
\entry{HOME}{61}{\code {HOME}}
\entry{IFS}{61}{\code {IFS}}
\entry{MAIL}{61}{\code {MAIL}}
\entry{MAILPATH}{61}{\code {MAILPATH}}
\entry{OPTARG}{61}{\code {OPTARG}}
\entry{OPTIND}{61}{\code {OPTIND}}
\entry{PATH}{61}{\code {PATH}}
\entry{PS1}{61}{\code {PS1}}
\entry{PS2}{61}{\code {PS2}}
\entry{BASH}{61}{\code {BASH}}
\entry{BASHOPTS}{62}{\code {BASHOPTS}}
\entry{BASHPID}{62}{\code {BASHPID}}
\entry{BASH_ALIASES}{62}{\code {BASH_ALIASES}}
\entry{BASH_ARGC}{62}{\code {BASH_ARGC}}
\entry{BASH_ARGV}{62}{\code {BASH_ARGV}}
\entry{BASH_CMDS}{62}{\code {BASH_CMDS}}
\entry{BASH_COMMAND}{62}{\code {BASH_COMMAND}}
\entry{BASH_ENV}{62}{\code {BASH_ENV}}
\entry{BASH_EXECUTION_STRING}{62}{\code {BASH_EXECUTION_STRING}}
\entry{BASH_LINENO}{63}{\code {BASH_LINENO}}
\entry{BASH_REMATCH}{63}{\code {BASH_REMATCH}}
\entry{BASH_SOURCE}{63}{\code {BASH_SOURCE}}
\entry{BASH_SUBSHELL}{63}{\code {BASH_SUBSHELL}}
\entry{BASH_VERSINFO}{63}{\code {BASH_VERSINFO}}
\entry{BASH_VERSION}{63}{\code {BASH_VERSION}}
\entry{BASH_XTRACEFD}{63}{\code {BASH_XTRACEFD}}
\entry{COLUMNS}{64}{\code {COLUMNS}}
\entry{COMP_CWORD}{64}{\code {COMP_CWORD}}
\entry{COMP_LINE}{64}{\code {COMP_LINE}}
\entry{COMP_POINT}{64}{\code {COMP_POINT}}
\entry{COMP_TYPE}{64}{\code {COMP_TYPE}}
\entry{COMP_KEY}{64}{\code {COMP_KEY}}
\entry{COMP_WORDBREAKS}{64}{\code {COMP_WORDBREAKS}}
\entry{COMP_WORDS}{64}{\code {COMP_WORDS}}
\entry{COMPREPLY}{65}{\code {COMPREPLY}}
\entry{COPROC}{65}{\code {COPROC}}
\entry{DIRSTACK}{65}{\code {DIRSTACK}}
\entry{EMACS}{65}{\code {EMACS}}
\entry{ENV}{65}{\code {ENV}}
\entry{EUID}{65}{\code {EUID}}
\entry{FCEDIT}{65}{\code {FCEDIT}}
\entry{FIGNORE}{65}{\code {FIGNORE}}
\entry{FUNCNAME}{65}{\code {FUNCNAME}}
\entry{GLOBIGNORE}{65}{\code {GLOBIGNORE}}
\entry{GROUPS}{65}{\code {GROUPS}}
\entry{histchars}{65}{\code {histchars}}
\entry{HISTCMD}{66}{\code {HISTCMD}}
\entry{HISTCONTROL}{66}{\code {HISTCONTROL}}
\entry{HISTFILE}{66}{\code {HISTFILE}}
\entry{HISTFILESIZE}{66}{\code {HISTFILESIZE}}
\entry{HISTIGNORE}{66}{\code {HISTIGNORE}}
\entry{HISTSIZE}{66}{\code {HISTSIZE}}
\entry{HISTTIMEFORMAT}{67}{\code {HISTTIMEFORMAT}}
\entry{HOSTFILE}{67}{\code {HOSTFILE}}
\entry{HOSTNAME}{67}{\code {HOSTNAME}}
\entry{HOSTTYPE}{67}{\code {HOSTTYPE}}
\entry{IGNOREEOF}{67}{\code {IGNOREEOF}}
\entry{INPUTRC}{67}{\code {INPUTRC}}
\entry{LANG}{67}{\code {LANG}}
\entry{LC_ALL}{67}{\code {LC_ALL}}
\entry{LC_COLLATE}{67}{\code {LC_COLLATE}}
\entry{LC_CTYPE}{67}{\code {LC_CTYPE}}
\entry{LC_MESSAGES}{67}{\code {LC_MESSAGES}}
\entry{LC_NUMERIC}{67}{\code {LC_NUMERIC}}
\entry{LINENO}{68}{\code {LINENO}}
\entry{LINES}{68}{\code {LINES}}
\entry{MACHTYPE}{68}{\code {MACHTYPE}}
\entry{MAILCHECK}{68}{\code {MAILCHECK}}
\entry{MAPFILE}{68}{\code {MAPFILE}}
\entry{OLDPWD}{68}{\code {OLDPWD}}
\entry{OPTERR}{68}{\code {OPTERR}}
\entry{OSTYPE}{68}{\code {OSTYPE}}
\entry{PIPESTATUS}{68}{\code {PIPESTATUS}}
\entry{POSIXLY_CORRECT}{68}{\code {POSIXLY_CORRECT}}
\entry{PPID}{68}{\code {PPID}}
\entry{PROMPT_COMMAND}{68}{\code {PROMPT_COMMAND}}
\entry{PROMPT_DIRTRIM}{68}{\code {PROMPT_DIRTRIM}}
\entry{PS3}{68}{\code {PS3}}
\entry{PS4}{69}{\code {PS4}}
\entry{PWD}{69}{\code {PWD}}
\entry{RANDOM}{69}{\code {RANDOM}}
\entry{READLINE_LINE}{69}{\code {READLINE_LINE}}
\entry{READLINE_POINT}{69}{\code {READLINE_POINT}}
\entry{REPLY}{69}{\code {REPLY}}
\entry{SECONDS}{69}{\code {SECONDS}}
\entry{SHELL}{69}{\code {SHELL}}
\entry{SHELLOPTS}{69}{\code {SHELLOPTS}}
\entry{SHLVL}{69}{\code {SHLVL}}
\entry{TIMEFORMAT}{69}{\code {TIMEFORMAT}}
\entry{TMOUT}{70}{\code {TMOUT}}
\entry{TMPDIR}{70}{\code {TMPDIR}}
\entry{UID}{70}{\code {UID}}
\entry{auto_resume}{92}{\code {auto_resume}}
\entry{bell-style}{97}{\code {bell-style}}
\entry{bind-tty-special-chars}{97}{\code {bind-tty-special-chars}}
\entry{comment-begin}{97}{\code {comment-begin}}
\entry{completion-display-width}{97}{\code {completion-display-width}}
\entry{completion-ignore-case}{97}{\code {completion-ignore-case}}
\entry{completion-prefix-display-length}{97}{\code {completion-prefix-display-length}}
\entry{completion-query-items}{97}{\code {completion-query-items}}
\entry{convert-meta}{98}{\code {convert-meta}}
\entry{disable-completion}{98}{\code {disable-completion}}
\entry{editing-mode}{98}{\code {editing-mode}}
\entry{enable-keypad}{98}{\code {enable-keypad}}
\entry{expand-tilde}{98}{\code {expand-tilde}}
\entry{history-preserve-point}{98}{\code {history-preserve-point}}
\entry{history-size}{98}{\code {history-size}}
\entry{horizontal-scroll-mode}{99}{\code {horizontal-scroll-mode}}
\entry{input-meta}{99}{\code {input-meta}}
\entry{meta-flag}{99}{\code {meta-flag}}
\entry{isearch-terminators}{99}{\code {isearch-terminators}}
\entry{keymap}{99}{\code {keymap}}
\entry{mark-modified-lines}{99}{\code {mark-modified-lines}}
\entry{mark-symlinked-directories}{99}{\code {mark-symlinked-directories}}
\entry{match-hidden-files}{99}{\code {match-hidden-files}}
\entry{output-meta}{99}{\code {output-meta}}
\entry{page-completions}{100}{\code {page-completions}}
\entry{revert-all-at-newline}{100}{\code {revert-all-at-newline}}
\entry{show-all-if-ambiguous}{100}{\code {show-all-if-ambiguous}}
\entry{show-all-if-unmodified}{100}{\code {show-all-if-unmodified}}
\entry{skip-completed-text}{100}{\code {skip-completed-text}}
\entry{visible-stats}{100}{\code {visible-stats}}
\entry{*}{18}{\code {*}}
\entry{@}{18}{\code {@}}
\entry{#}{18}{\code {#}}
\entry{?}{18}{\code {?}}
\entry{-}{18}{\code {-}}
\entry{$}{18}{\code {$}}
\entry{!}{18}{\code {!}}
\entry{0}{18}{\code {0}}
\entry{_}{18}{\code {_}}
\entry{CDPATH}{63}{\code {CDPATH}}
\entry{HOME}{63}{\code {HOME}}
\entry{IFS}{63}{\code {IFS}}
\entry{MAIL}{63}{\code {MAIL}}
\entry{MAILPATH}{63}{\code {MAILPATH}}
\entry{OPTARG}{63}{\code {OPTARG}}
\entry{OPTIND}{63}{\code {OPTIND}}
\entry{PATH}{63}{\code {PATH}}
\entry{PS1}{63}{\code {PS1}}
\entry{PS2}{63}{\code {PS2}}
\entry{BASH}{63}{\code {BASH}}
\entry{BASHOPTS}{64}{\code {BASHOPTS}}
\entry{BASHPID}{64}{\code {BASHPID}}
\entry{BASH_ALIASES}{64}{\code {BASH_ALIASES}}
\entry{BASH_ARGC}{64}{\code {BASH_ARGC}}
\entry{BASH_ARGV}{64}{\code {BASH_ARGV}}
\entry{BASH_CMDS}{64}{\code {BASH_CMDS}}
\entry{BASH_COMMAND}{64}{\code {BASH_COMMAND}}
\entry{BASH_ENV}{64}{\code {BASH_ENV}}
\entry{BASH_EXECUTION_STRING}{64}{\code {BASH_EXECUTION_STRING}}
\entry{BASH_LINENO}{65}{\code {BASH_LINENO}}
\entry{BASH_REMATCH}{65}{\code {BASH_REMATCH}}
\entry{BASH_SOURCE}{65}{\code {BASH_SOURCE}}
\entry{BASH_SUBSHELL}{65}{\code {BASH_SUBSHELL}}
\entry{BASH_VERSINFO}{65}{\code {BASH_VERSINFO}}
\entry{BASH_VERSION}{65}{\code {BASH_VERSION}}
\entry{BASH_XTRACEFD}{65}{\code {BASH_XTRACEFD}}
\entry{COLUMNS}{66}{\code {COLUMNS}}
\entry{COMP_CWORD}{66}{\code {COMP_CWORD}}
\entry{COMP_LINE}{66}{\code {COMP_LINE}}
\entry{COMP_POINT}{66}{\code {COMP_POINT}}
\entry{COMP_TYPE}{66}{\code {COMP_TYPE}}
\entry{COMP_KEY}{66}{\code {COMP_KEY}}
\entry{COMP_WORDBREAKS}{66}{\code {COMP_WORDBREAKS}}
\entry{COMP_WORDS}{66}{\code {COMP_WORDS}}
\entry{COMPREPLY}{67}{\code {COMPREPLY}}
\entry{COPROC}{67}{\code {COPROC}}
\entry{DIRSTACK}{67}{\code {DIRSTACK}}
\entry{EMACS}{67}{\code {EMACS}}
\entry{ENV}{67}{\code {ENV}}
\entry{EUID}{67}{\code {EUID}}
\entry{FCEDIT}{67}{\code {FCEDIT}}
\entry{FIGNORE}{67}{\code {FIGNORE}}
\entry{FUNCNAME}{67}{\code {FUNCNAME}}
\entry{FUNCNEST}{67}{\code {FUNCNEST}}
\entry{GLOBIGNORE}{67}{\code {GLOBIGNORE}}
\entry{GROUPS}{67}{\code {GROUPS}}
\entry{histchars}{68}{\code {histchars}}
\entry{HISTCMD}{68}{\code {HISTCMD}}
\entry{HISTCONTROL}{68}{\code {HISTCONTROL}}
\entry{HISTFILE}{68}{\code {HISTFILE}}
\entry{HISTFILESIZE}{68}{\code {HISTFILESIZE}}
\entry{HISTIGNORE}{68}{\code {HISTIGNORE}}
\entry{HISTSIZE}{69}{\code {HISTSIZE}}
\entry{HISTTIMEFORMAT}{69}{\code {HISTTIMEFORMAT}}
\entry{HOSTFILE}{69}{\code {HOSTFILE}}
\entry{HOSTNAME}{69}{\code {HOSTNAME}}
\entry{HOSTTYPE}{69}{\code {HOSTTYPE}}
\entry{IGNOREEOF}{69}{\code {IGNOREEOF}}
\entry{INPUTRC}{69}{\code {INPUTRC}}
\entry{LANG}{69}{\code {LANG}}
\entry{LC_ALL}{69}{\code {LC_ALL}}
\entry{LC_COLLATE}{69}{\code {LC_COLLATE}}
\entry{LC_CTYPE}{69}{\code {LC_CTYPE}}
\entry{LC_MESSAGES}{70}{\code {LC_MESSAGES}}
\entry{LC_NUMERIC}{70}{\code {LC_NUMERIC}}
\entry{LINENO}{70}{\code {LINENO}}
\entry{LINES}{70}{\code {LINES}}
\entry{MACHTYPE}{70}{\code {MACHTYPE}}
\entry{MAILCHECK}{70}{\code {MAILCHECK}}
\entry{MAPFILE}{70}{\code {MAPFILE}}
\entry{OLDPWD}{70}{\code {OLDPWD}}
\entry{OPTERR}{70}{\code {OPTERR}}
\entry{OSTYPE}{70}{\code {OSTYPE}}
\entry{PIPESTATUS}{70}{\code {PIPESTATUS}}
\entry{POSIXLY_CORRECT}{70}{\code {POSIXLY_CORRECT}}
\entry{PPID}{70}{\code {PPID}}
\entry{PROMPT_COMMAND}{70}{\code {PROMPT_COMMAND}}
\entry{PROMPT_DIRTRIM}{70}{\code {PROMPT_DIRTRIM}}
\entry{PS3}{71}{\code {PS3}}
\entry{PS4}{71}{\code {PS4}}
\entry{PWD}{71}{\code {PWD}}
\entry{RANDOM}{71}{\code {RANDOM}}
\entry{READLINE_LINE}{71}{\code {READLINE_LINE}}
\entry{READLINE_POINT}{71}{\code {READLINE_POINT}}
\entry{REPLY}{71}{\code {REPLY}}
\entry{SECONDS}{71}{\code {SECONDS}}
\entry{SHELL}{71}{\code {SHELL}}
\entry{SHELLOPTS}{71}{\code {SHELLOPTS}}
\entry{SHLVL}{71}{\code {SHLVL}}
\entry{TIMEFORMAT}{71}{\code {TIMEFORMAT}}
\entry{TMOUT}{72}{\code {TMOUT}}
\entry{TMPDIR}{72}{\code {TMPDIR}}
\entry{UID}{72}{\code {UID}}
\entry{auto_resume}{94}{\code {auto_resume}}
\entry{bell-style}{99}{\code {bell-style}}
\entry{bind-tty-special-chars}{99}{\code {bind-tty-special-chars}}
\entry{comment-begin}{99}{\code {comment-begin}}
\entry{completion-display-width}{99}{\code {completion-display-width}}
\entry{completion-ignore-case}{99}{\code {completion-ignore-case}}
\entry{completion-map-case}{99}{\code {completion-map-case}}
\entry{completion-prefix-display-length}{99}{\code {completion-prefix-display-length}}
\entry{completion-query-items}{100}{\code {completion-query-items}}
\entry{convert-meta}{100}{\code {convert-meta}}
\entry{disable-completion}{100}{\code {disable-completion}}
\entry{editing-mode}{100}{\code {editing-mode}}
\entry{enable-keypad}{100}{\code {enable-keypad}}
\entry{expand-tilde}{100}{\code {expand-tilde}}
\entry{history-preserve-point}{100}{\code {history-preserve-point}}
\entry{history-size}{101}{\code {history-size}}
\entry{horizontal-scroll-mode}{101}{\code {horizontal-scroll-mode}}
\entry{input-meta}{101}{\code {input-meta}}
\entry{meta-flag}{101}{\code {meta-flag}}
\entry{isearch-terminators}{101}{\code {isearch-terminators}}
\entry{keymap}{101}{\code {keymap}}
\entry{mark-modified-lines}{101}{\code {mark-modified-lines}}
\entry{mark-symlinked-directories}{101}{\code {mark-symlinked-directories}}
\entry{match-hidden-files}{101}{\code {match-hidden-files}}
\entry{output-meta}{102}{\code {output-meta}}
\entry{page-completions}{102}{\code {page-completions}}
\entry{revert-all-at-newline}{102}{\code {revert-all-at-newline}}
\entry{show-all-if-ambiguous}{102}{\code {show-all-if-ambiguous}}
\entry{show-all-if-unmodified}{102}{\code {show-all-if-unmodified}}
\entry{skip-completed-text}{102}{\code {skip-completed-text}}
\entry{visible-stats}{102}{\code {visible-stats}}
+134 -132
View File
@@ -1,162 +1,164 @@
\initial {!}
\entry {\code {!}}{17}
\entry {\code {!}}{18}
\initial {#}
\entry {\code {#}}{17}
\entry {\code {#}}{18}
\initial {$}
\entry {\code {$}}{17}
\entry {\code {$}}{18}
\initial {*}
\entry {\code {*}}{16}
\entry {\code {*}}{18}
\initial {-}
\entry {\code {-}}{17}
\entry {\code {-}}{18}
\initial {?}
\entry {\code {?}}{17}
\entry {\code {?}}{18}
\initial {@}
\entry {\code {@}}{16}
\entry {\code {@}}{18}
\initial {_}
\entry {\code {_}}{17}
\entry {\code {_}}{18}
\initial {0}
\entry {\code {0}}{17}
\entry {\code {0}}{18}
\initial {A}
\entry {\code {auto_resume}}{92}
\entry {\code {auto_resume}}{94}
\initial {B}
\entry {\code {BASH}}{61}
\entry {\code {BASH_ALIASES}}{62}
\entry {\code {BASH_ARGC}}{62}
\entry {\code {BASH_ARGV}}{62}
\entry {\code {BASH_CMDS}}{62}
\entry {\code {BASH_COMMAND}}{62}
\entry {\code {BASH_ENV}}{62}
\entry {\code {BASH_EXECUTION_STRING}}{62}
\entry {\code {BASH_LINENO}}{63}
\entry {\code {BASH_REMATCH}}{63}
\entry {\code {BASH_SOURCE}}{63}
\entry {\code {BASH_SUBSHELL}}{63}
\entry {\code {BASH_VERSINFO}}{63}
\entry {\code {BASH_VERSION}}{63}
\entry {\code {BASH_XTRACEFD}}{63}
\entry {\code {BASHOPTS}}{62}
\entry {\code {BASHPID}}{62}
\entry {\code {bell-style}}{97}
\entry {\code {bind-tty-special-chars}}{97}
\entry {\code {BASH}}{63}
\entry {\code {BASH_ALIASES}}{64}
\entry {\code {BASH_ARGC}}{64}
\entry {\code {BASH_ARGV}}{64}
\entry {\code {BASH_CMDS}}{64}
\entry {\code {BASH_COMMAND}}{64}
\entry {\code {BASH_ENV}}{64}
\entry {\code {BASH_EXECUTION_STRING}}{64}
\entry {\code {BASH_LINENO}}{65}
\entry {\code {BASH_REMATCH}}{65}
\entry {\code {BASH_SOURCE}}{65}
\entry {\code {BASH_SUBSHELL}}{65}
\entry {\code {BASH_VERSINFO}}{65}
\entry {\code {BASH_VERSION}}{65}
\entry {\code {BASH_XTRACEFD}}{65}
\entry {\code {BASHOPTS}}{64}
\entry {\code {BASHPID}}{64}
\entry {\code {bell-style}}{99}
\entry {\code {bind-tty-special-chars}}{99}
\initial {C}
\entry {\code {CDPATH}}{61}
\entry {\code {COLUMNS}}{64}
\entry {\code {comment-begin}}{97}
\entry {\code {COMP_CWORD}}{64}
\entry {\code {COMP_KEY}}{64}
\entry {\code {COMP_LINE}}{64}
\entry {\code {COMP_POINT}}{64}
\entry {\code {COMP_TYPE}}{64}
\entry {\code {COMP_WORDBREAKS}}{64}
\entry {\code {COMP_WORDS}}{64}
\entry {\code {completion-display-width}}{97}
\entry {\code {completion-ignore-case}}{97}
\entry {\code {completion-prefix-display-length}}{97}
\entry {\code {completion-query-items}}{97}
\entry {\code {COMPREPLY}}{65}
\entry {\code {convert-meta}}{98}
\entry {\code {COPROC}}{65}
\entry {\code {CDPATH}}{63}
\entry {\code {COLUMNS}}{66}
\entry {\code {comment-begin}}{99}
\entry {\code {COMP_CWORD}}{66}
\entry {\code {COMP_KEY}}{66}
\entry {\code {COMP_LINE}}{66}
\entry {\code {COMP_POINT}}{66}
\entry {\code {COMP_TYPE}}{66}
\entry {\code {COMP_WORDBREAKS}}{66}
\entry {\code {COMP_WORDS}}{66}
\entry {\code {completion-display-width}}{99}
\entry {\code {completion-ignore-case}}{99}
\entry {\code {completion-map-case}}{99}
\entry {\code {completion-prefix-display-length}}{99}
\entry {\code {completion-query-items}}{100}
\entry {\code {COMPREPLY}}{67}
\entry {\code {convert-meta}}{100}
\entry {\code {COPROC}}{67}
\initial {D}
\entry {\code {DIRSTACK}}{65}
\entry {\code {disable-completion}}{98}
\entry {\code {DIRSTACK}}{67}
\entry {\code {disable-completion}}{100}
\initial {E}
\entry {\code {editing-mode}}{98}
\entry {\code {EMACS}}{65}
\entry {\code {enable-keypad}}{98}
\entry {\code {ENV}}{65}
\entry {\code {EUID}}{65}
\entry {\code {expand-tilde}}{98}
\entry {\code {editing-mode}}{100}
\entry {\code {EMACS}}{67}
\entry {\code {enable-keypad}}{100}
\entry {\code {ENV}}{67}
\entry {\code {EUID}}{67}
\entry {\code {expand-tilde}}{100}
\initial {F}
\entry {\code {FCEDIT}}{65}
\entry {\code {FIGNORE}}{65}
\entry {\code {FUNCNAME}}{65}
\entry {\code {FCEDIT}}{67}
\entry {\code {FIGNORE}}{67}
\entry {\code {FUNCNAME}}{67}
\entry {\code {FUNCNEST}}{67}
\initial {G}
\entry {\code {GLOBIGNORE}}{65}
\entry {\code {GROUPS}}{65}
\entry {\code {GLOBIGNORE}}{67}
\entry {\code {GROUPS}}{67}
\initial {H}
\entry {\code {histchars}}{65}
\entry {\code {HISTCMD}}{66}
\entry {\code {HISTCONTROL}}{66}
\entry {\code {HISTFILE}}{66}
\entry {\code {HISTFILESIZE}}{66}
\entry {\code {HISTIGNORE}}{66}
\entry {\code {history-preserve-point}}{98}
\entry {\code {history-size}}{98}
\entry {\code {HISTSIZE}}{66}
\entry {\code {HISTTIMEFORMAT}}{67}
\entry {\code {HOME}}{61}
\entry {\code {horizontal-scroll-mode}}{99}
\entry {\code {HOSTFILE}}{67}
\entry {\code {HOSTNAME}}{67}
\entry {\code {HOSTTYPE}}{67}
\entry {\code {histchars}}{68}
\entry {\code {HISTCMD}}{68}
\entry {\code {HISTCONTROL}}{68}
\entry {\code {HISTFILE}}{68}
\entry {\code {HISTFILESIZE}}{68}
\entry {\code {HISTIGNORE}}{68}
\entry {\code {history-preserve-point}}{100}
\entry {\code {history-size}}{101}
\entry {\code {HISTSIZE}}{69}
\entry {\code {HISTTIMEFORMAT}}{69}
\entry {\code {HOME}}{63}
\entry {\code {horizontal-scroll-mode}}{101}
\entry {\code {HOSTFILE}}{69}
\entry {\code {HOSTNAME}}{69}
\entry {\code {HOSTTYPE}}{69}
\initial {I}
\entry {\code {IFS}}{61}
\entry {\code {IGNOREEOF}}{67}
\entry {\code {input-meta}}{99}
\entry {\code {INPUTRC}}{67}
\entry {\code {isearch-terminators}}{99}
\entry {\code {IFS}}{63}
\entry {\code {IGNOREEOF}}{69}
\entry {\code {input-meta}}{101}
\entry {\code {INPUTRC}}{69}
\entry {\code {isearch-terminators}}{101}
\initial {K}
\entry {\code {keymap}}{99}
\entry {\code {keymap}}{101}
\initial {L}
\entry {\code {LANG}}{67}
\entry {\code {LC_ALL}}{67}
\entry {\code {LC_COLLATE}}{67}
\entry {\code {LC_CTYPE}}{67}
\entry {\code {LC_MESSAGES}}{7, 67}
\entry {\code {LC_NUMERIC}}{67}
\entry {\code {LINENO}}{68}
\entry {\code {LINES}}{68}
\entry {\code {LANG}}{69}
\entry {\code {LC_ALL}}{69}
\entry {\code {LC_COLLATE}}{69}
\entry {\code {LC_CTYPE}}{69}
\entry {\code {LC_MESSAGES}}{7, 70}
\entry {\code {LC_NUMERIC}}{70}
\entry {\code {LINENO}}{70}
\entry {\code {LINES}}{70}
\initial {M}
\entry {\code {MACHTYPE}}{68}
\entry {\code {MAIL}}{61}
\entry {\code {MAILCHECK}}{68}
\entry {\code {MAILPATH}}{61}
\entry {\code {MAPFILE}}{68}
\entry {\code {mark-modified-lines}}{99}
\entry {\code {mark-symlinked-directories}}{99}
\entry {\code {match-hidden-files}}{99}
\entry {\code {meta-flag}}{99}
\entry {\code {MACHTYPE}}{70}
\entry {\code {MAIL}}{63}
\entry {\code {MAILCHECK}}{70}
\entry {\code {MAILPATH}}{63}
\entry {\code {MAPFILE}}{70}
\entry {\code {mark-modified-lines}}{101}
\entry {\code {mark-symlinked-directories}}{101}
\entry {\code {match-hidden-files}}{101}
\entry {\code {meta-flag}}{101}
\initial {O}
\entry {\code {OLDPWD}}{68}
\entry {\code {OPTARG}}{61}
\entry {\code {OPTERR}}{68}
\entry {\code {OPTIND}}{61}
\entry {\code {OSTYPE}}{68}
\entry {\code {output-meta}}{99}
\entry {\code {OLDPWD}}{70}
\entry {\code {OPTARG}}{63}
\entry {\code {OPTERR}}{70}
\entry {\code {OPTIND}}{63}
\entry {\code {OSTYPE}}{70}
\entry {\code {output-meta}}{102}
\initial {P}
\entry {\code {page-completions}}{100}
\entry {\code {PATH}}{61}
\entry {\code {PIPESTATUS}}{68}
\entry {\code {POSIXLY_CORRECT}}{68}
\entry {\code {PPID}}{68}
\entry {\code {PROMPT_COMMAND}}{68}
\entry {\code {PROMPT_DIRTRIM}}{68}
\entry {\code {PS1}}{61}
\entry {\code {PS2}}{61}
\entry {\code {PS3}}{68}
\entry {\code {PS4}}{69}
\entry {\code {PWD}}{69}
\entry {\code {page-completions}}{102}
\entry {\code {PATH}}{63}
\entry {\code {PIPESTATUS}}{70}
\entry {\code {POSIXLY_CORRECT}}{70}
\entry {\code {PPID}}{70}
\entry {\code {PROMPT_COMMAND}}{70}
\entry {\code {PROMPT_DIRTRIM}}{70}
\entry {\code {PS1}}{63}
\entry {\code {PS2}}{63}
\entry {\code {PS3}}{71}
\entry {\code {PS4}}{71}
\entry {\code {PWD}}{71}
\initial {R}
\entry {\code {RANDOM}}{69}
\entry {\code {READLINE_LINE}}{69}
\entry {\code {READLINE_POINT}}{69}
\entry {\code {REPLY}}{69}
\entry {\code {revert-all-at-newline}}{100}
\entry {\code {RANDOM}}{71}
\entry {\code {READLINE_LINE}}{71}
\entry {\code {READLINE_POINT}}{71}
\entry {\code {REPLY}}{71}
\entry {\code {revert-all-at-newline}}{102}
\initial {S}
\entry {\code {SECONDS}}{69}
\entry {\code {SHELL}}{69}
\entry {\code {SHELLOPTS}}{69}
\entry {\code {SHLVL}}{69}
\entry {\code {show-all-if-ambiguous}}{100}
\entry {\code {show-all-if-unmodified}}{100}
\entry {\code {skip-completed-text}}{100}
\entry {\code {SECONDS}}{71}
\entry {\code {SHELL}}{71}
\entry {\code {SHELLOPTS}}{71}
\entry {\code {SHLVL}}{71}
\entry {\code {show-all-if-ambiguous}}{102}
\entry {\code {show-all-if-unmodified}}{102}
\entry {\code {skip-completed-text}}{102}
\initial {T}
\entry {\code {TEXTDOMAIN}}{7}
\entry {\code {TEXTDOMAINDIR}}{7}
\entry {\code {TIMEFORMAT}}{69}
\entry {\code {TMOUT}}{70}
\entry {\code {TMPDIR}}{70}
\entry {\code {TIMEFORMAT}}{71}
\entry {\code {TMOUT}}{72}
\entry {\code {TMPDIR}}{72}
\initial {U}
\entry {\code {UID}}{70}
\entry {\code {UID}}{72}
\initial {V}
\entry {\code {visible-stats}}{100}
\entry {\code {visible-stats}}{102}
+599 -582
View File
File diff suppressed because it is too large Load Diff
+1471 -1448
View File
File diff suppressed because it is too large Load Diff
+1 -1
View File
@@ -1,6 +1,6 @@
%!PS-Adobe-3.0
%%Creator: groff version 1.19.2
%%CreationDate: Thu May 20 16:33:07 2010
%%CreationDate: Tue Jun 1 11:58:36 2010
%%DocumentNeededResources: font Times-Roman
%%+ font Times-Bold
%%DocumentSuppliedResources: procset grops 1.19 2
+25 -2
View File
@@ -136,6 +136,7 @@ static int builtin_status __P((int));
static int execute_for_command __P((FOR_COM *));
#if defined (SELECT_COMMAND)
static int displen __P((const char *));
static int print_index_and_element __P((int, int, WORD_LIST *));
static void indent __P((int, int));
static void print_select_list __P((WORD_LIST *, int, int, int));
@@ -2639,6 +2640,28 @@ static int LINES, COLS, tabsize;
: ((s < 100000) ? 5 \
: 6)))))
static int
displen (s)
const char *s;
{
#if defined (HANDLE_MULTIBYTE)
wchar_t *wcstr;
size_t wclen, slen;
wcstr = 0;
slen = mbstowcs (wcstr, s, 0);
if (slen == -1)
slen = 0;
wcstr = (wchar_t *)xmalloc (sizeof (wchar_t) * (slen + 1));
mbstowcs (wcstr, s, slen + 1);
wclen = wcswidth (wcstr, slen);
free (wcstr);
return ((int)wclen);
#else
return (STRLEN (s));
#endif
}
static int
print_index_and_element (len, ind, list)
int len, ind;
@@ -2652,7 +2675,7 @@ print_index_and_element (len, ind, list)
for (i = ind, l = list; l && --i; l = l->next)
;
fprintf (stderr, "%*d%s%s", len, ind, RP_SPACE, l->word->word);
return (STRLEN (l->word->word));
return (displen (l->word->word));
}
static void
@@ -2758,7 +2781,7 @@ select_query (list, list_len, prompt, print_menu)
max_elem_len = 0;
for (l = list; l; l = l->next)
{
len = STRLEN (l->word->word);
len = displen (l->word->word);
if (len > max_elem_len)
max_elem_len = len;
}
+25 -3
View File
@@ -1,6 +1,6 @@
/* execute_cmd.c -- Execute a COMMAND structure. */
/* Copyright (C) 1987-2009 Free Software Foundation, Inc.
/* Copyright (C) 1987-2010 Free Software Foundation, Inc.
This file is part of GNU Bash, the Bourne Again SHell.
@@ -2639,6 +2639,28 @@ static int LINES, COLS, tabsize;
: ((s < 100000) ? 5 \
: 6)))))
static int
displen (s)
char *s;
{
#if defined (HANDLE_MULTIBYTE)
wchar_t *wcstr;
size_t wclen, slen;
wcstr = 0;
slen = mbstowcs (wcstr, s, 0);
if (slen == -1)
slen = 0;
wcstr = (wchar_t *)xmalloc (sizeof (wchar_t) * (slen + 1));
mbstowcs (wcstr, s, slen + 1);
wclen = wcswidth (wcstr, slen);
free (wcstr);
return ((int)wclen);
#else
return (STRLEN (s));
#endif
}
static int
print_index_and_element (len, ind, list)
int len, ind;
@@ -2652,7 +2674,7 @@ print_index_and_element (len, ind, list)
for (i = ind, l = list; l && --i; l = l->next)
;
fprintf (stderr, "%*d%s%s", len, ind, RP_SPACE, l->word->word);
return (STRLEN (l->word->word));
return (displen (l->word->word));
}
static void
@@ -2758,7 +2780,7 @@ select_query (list, list_len, prompt, print_menu)
max_elem_len = 0;
for (l = list; l; l = l->next)
{
len = STRLEN (l->word->word);
len = displen (l->word->word);
if (len > max_elem_len)
max_elem_len = len;
}
+9
View File
@@ -142,6 +142,15 @@ rl_callback_read_char ()
eof = _rl_nsearch_callback (_rl_nscxt);
return;
}
#if defined (VI_MODE)
else if (RL_ISSTATE (RL_STATE_VIMOTION))
{
eof = _rl_vi_domove_callback (_rl_vimvcxt);
/* Should handle everything, including cleanup, numeric arguments,
and turning off RL_STATE_VIMOTION */
return;
}
#endif
else if (RL_ISSTATE (RL_STATE_NUMERICARG))
{
eof = _rl_arg_callback (_rl_argcxt);
+270
View File
@@ -0,0 +1,270 @@
/* callback.c -- functions to use readline as an X `callback' mechanism. */
/* Copyright (C) 1987-2009 Free Software Foundation, Inc.
This file is part of the GNU Readline Library (Readline), a library
for reading lines of text with interactive input and history editing.
Readline is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Readline is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Readline. If not, see <http://www.gnu.org/licenses/>.
*/
#define READLINE_LIBRARY
#if defined (HAVE_CONFIG_H)
# include <config.h>
#endif
#include "rlconf.h"
#if defined (READLINE_CALLBACKS)
#include <sys/types.h>
#ifdef HAVE_STDLIB_H
# include <stdlib.h>
#else
# include "ansi_stdlib.h"
#endif
#include <stdio.h>
/* System-specific feature definitions and include files. */
#include "rldefs.h"
#include "readline.h"
#include "rlprivate.h"
#include "xmalloc.h"
/* Private data for callback registration functions. See comments in
rl_callback_read_char for more details. */
_rl_callback_func_t *_rl_callback_func = 0;
_rl_callback_generic_arg *_rl_callback_data = 0;
/* **************************************************************** */
/* */
/* Callback Readline Functions */
/* */
/* **************************************************************** */
/* Allow using readline in situations where a program may have multiple
things to handle at once, and dispatches them via select(). Call
rl_callback_handler_install() with the prompt and a function to call
whenever a complete line of input is ready. The user must then
call rl_callback_read_char() every time some input is available, and
rl_callback_read_char() will call the user's function with the complete
text read in at each end of line. The terminal is kept prepped and
signals handled all the time, except during calls to the user's function. */
rl_vcpfunc_t *rl_linefunc; /* user callback function */
static int in_handler; /* terminal_prepped and signals set? */
/* Make sure the terminal is set up, initialize readline, and prompt. */
static void
_rl_callback_newline ()
{
rl_initialize ();
if (in_handler == 0)
{
in_handler = 1;
if (rl_prep_term_function)
(*rl_prep_term_function) (_rl_meta_flag);
#if defined (HANDLE_SIGNALS)
rl_set_signals ();
#endif
}
readline_internal_setup ();
RL_CHECK_SIGNALS ();
}
/* Install a readline handler, set up the terminal, and issue the prompt. */
void
rl_callback_handler_install (prompt, linefunc)
const char *prompt;
rl_vcpfunc_t *linefunc;
{
rl_set_prompt (prompt);
RL_SETSTATE (RL_STATE_CALLBACK);
rl_linefunc = linefunc;
_rl_callback_newline ();
}
/* Read one character, and dispatch to the handler if it ends the line. */
void
rl_callback_read_char ()
{
char *line;
int eof, jcode;
static procenv_t olevel;
if (rl_linefunc == NULL)
{
_rl_errmsg ("readline_callback_read_char() called with no handler!");
abort ();
}
memcpy ((void *)olevel, (void *)_rl_top_level, sizeof (procenv_t));
jcode = setjmp (_rl_top_level);
if (jcode)
{
(*rl_redisplay_function) ();
_rl_want_redisplay = 0;
memcpy ((void *)_rl_top_level, (void *)olevel, sizeof (procenv_t));
return;
}
do
{
RL_CHECK_SIGNALS ();
if (RL_ISSTATE (RL_STATE_ISEARCH))
{
eof = _rl_isearch_callback (_rl_iscxt);
if (eof == 0 && (RL_ISSTATE (RL_STATE_ISEARCH) == 0) && RL_ISSTATE (RL_STATE_INPUTPENDING))
rl_callback_read_char ();
return;
}
else if (RL_ISSTATE (RL_STATE_NSEARCH))
{
eof = _rl_nsearch_callback (_rl_nscxt);
return;
}
#if defined (VI_MODE)
else if (RL_ISSTATE (RL_STATE_VIMOTION))
{
eof = _rl_vi_domove_callback (_rl_vimvcxt);
/* Should handle everything, including cleanup and turning off
RL_STATE_VIMOTION */
return;
}
#endif
else if (RL_ISSTATE (RL_STATE_NUMERICARG))
{
eof = _rl_arg_callback (_rl_argcxt);
if (eof == 0 && (RL_ISSTATE (RL_STATE_NUMERICARG) == 0) && RL_ISSTATE (RL_STATE_INPUTPENDING))
rl_callback_read_char ();
/* XXX - this should handle _rl_last_command_was_kill better */
else if (RL_ISSTATE (RL_STATE_NUMERICARG) == 0)
_rl_internal_char_cleanup ();
return;
}
else if (RL_ISSTATE (RL_STATE_MULTIKEY))
{
eof = _rl_dispatch_callback (_rl_kscxt); /* For now */
while ((eof == -1 || eof == -2) && RL_ISSTATE (RL_STATE_MULTIKEY) && _rl_kscxt && (_rl_kscxt->flags & KSEQ_DISPATCHED))
eof = _rl_dispatch_callback (_rl_kscxt);
if (RL_ISSTATE (RL_STATE_MULTIKEY) == 0)
{
_rl_internal_char_cleanup ();
_rl_want_redisplay = 1;
}
}
else if (_rl_callback_func)
{
/* This allows functions that simply need to read an additional
character (like quoted-insert) to register a function to be
called when input is available. _rl_callback_data is simply a
pointer to a struct that has the argument count originally
passed to the registering function and space for any additional
parameters. */
eof = (*_rl_callback_func) (_rl_callback_data);
/* If the function `deregisters' itself, make sure the data is
cleaned up. */
if (_rl_callback_func == 0)
{
if (_rl_callback_data)
{
_rl_callback_data_dispose (_rl_callback_data);
_rl_callback_data = 0;
}
_rl_internal_char_cleanup ();
}
}
else
eof = readline_internal_char ();
RL_CHECK_SIGNALS ();
if (rl_done == 0 && _rl_want_redisplay)
{
(*rl_redisplay_function) ();
_rl_want_redisplay = 0;
}
if (rl_done)
{
line = readline_internal_teardown (eof);
if (rl_deprep_term_function)
(*rl_deprep_term_function) ();
#if defined (HANDLE_SIGNALS)
rl_clear_signals ();
#endif
in_handler = 0;
(*rl_linefunc) (line);
/* If the user did not clear out the line, do it for him. */
if (rl_line_buffer[0])
_rl_init_line_state ();
/* Redisplay the prompt if readline_handler_{install,remove}
not called. */
if (in_handler == 0 && rl_linefunc)
_rl_callback_newline ();
}
}
while (rl_pending_input || _rl_pushed_input_available () || RL_ISSTATE (RL_STATE_MACROINPUT));
}
/* Remove the handler, and make sure the terminal is in its normal state. */
void
rl_callback_handler_remove ()
{
rl_linefunc = NULL;
RL_UNSETSTATE (RL_STATE_CALLBACK);
RL_CHECK_SIGNALS ();
if (in_handler)
{
in_handler = 0;
if (rl_deprep_term_function)
(*rl_deprep_term_function) ();
#if defined (HANDLE_SIGNALS)
rl_clear_signals ();
#endif
}
}
_rl_callback_generic_arg *
_rl_callback_data_alloc (count)
int count;
{
_rl_callback_generic_arg *arg;
arg = (_rl_callback_generic_arg *)xmalloc (sizeof (_rl_callback_generic_arg));
arg->count = count;
arg->i1 = arg->i2 = 0;
return arg;
}
void _rl_callback_data_dispose (arg)
_rl_callback_generic_arg *arg;
{
xfree (arg);
}
#endif
+24 -24
View File
@@ -805,30 +805,30 @@ extern int rl_inhibit_completion;
/* Possible state values for rl_readline_state */
#define RL_STATE_NONE 0x000000 /* no state; before first call */
#define RL_STATE_INITIALIZING 0x000001 /* initializing */
#define RL_STATE_INITIALIZED 0x000002 /* initialization done */
#define RL_STATE_TERMPREPPED 0x000004 /* terminal is prepped */
#define RL_STATE_READCMD 0x000008 /* reading a command key */
#define RL_STATE_METANEXT 0x000010 /* reading input after ESC */
#define RL_STATE_DISPATCHING 0x000020 /* dispatching to a command */
#define RL_STATE_MOREINPUT 0x000040 /* reading more input in a command function */
#define RL_STATE_ISEARCH 0x000080 /* doing incremental search */
#define RL_STATE_NSEARCH 0x000100 /* doing non-inc search */
#define RL_STATE_SEARCH 0x000200 /* doing a history search */
#define RL_STATE_NUMERICARG 0x000400 /* reading numeric argument */
#define RL_STATE_MACROINPUT 0x000800 /* getting input from a macro */
#define RL_STATE_MACRODEF 0x001000 /* defining keyboard macro */
#define RL_STATE_OVERWRITE 0x002000 /* overwrite mode */
#define RL_STATE_COMPLETING 0x004000 /* doing completion */
#define RL_STATE_SIGHANDLER 0x008000 /* in readline sighandler */
#define RL_STATE_UNDOING 0x010000 /* doing an undo */
#define RL_STATE_INPUTPENDING 0x020000 /* rl_execute_next called */
#define RL_STATE_TTYCSAVED 0x040000 /* tty special chars saved */
#define RL_STATE_CALLBACK 0x080000 /* using the callback interface */
#define RL_STATE_VIMOTION 0x100000 /* reading vi motion arg */
#define RL_STATE_MULTIKEY 0x200000 /* reading multiple-key command */
#define RL_STATE_VICMDONCE 0x400000 /* entered vi command mode at least once */
#define RL_STATE_REDISPLAYING 0x800000 /* updating terminal display */
#define RL_STATE_INITIALIZING 0x0000001 /* initializing */
#define RL_STATE_INITIALIZED 0x0000002 /* initialization done */
#define RL_STATE_TERMPREPPED 0x0000004 /* terminal is prepped */
#define RL_STATE_READCMD 0x0000008 /* reading a command key */
#define RL_STATE_METANEXT 0x0000010 /* reading input after ESC */
#define RL_STATE_DISPATCHING 0x0000020 /* dispatching to a command */
#define RL_STATE_MOREINPUT 0x0000040 /* reading more input in a command function */
#define RL_STATE_ISEARCH 0x0000080 /* doing incremental search */
#define RL_STATE_NSEARCH 0x0000100 /* doing non-inc search */
#define RL_STATE_SEARCH 0x0000200 /* doing a history search */
#define RL_STATE_NUMERICARG 0x0000400 /* reading numeric argument */
#define RL_STATE_MACROINPUT 0x0000800 /* getting input from a macro */
#define RL_STATE_MACRODEF 0x0001000 /* defining keyboard macro */
#define RL_STATE_OVERWRITE 0x0002000 /* overwrite mode */
#define RL_STATE_COMPLETING 0x0004000 /* doing completion */
#define RL_STATE_SIGHANDLER 0x0008000 /* in readline sighandler */
#define RL_STATE_UNDOING 0x0010000 /* doing an undo */
#define RL_STATE_INPUTPENDING 0x0020000 /* rl_execute_next called */
#define RL_STATE_TTYCSAVED 0x0040000 /* tty special chars saved */
#define RL_STATE_CALLBACK 0x0080000 /* using the callback interface */
#define RL_STATE_VIMOTION 0x0100000 /* reading vi motion arg */
#define RL_STATE_MULTIKEY 0x0200000 /* reading multiple-key command */
#define RL_STATE_VICMDONCE 0x0400000 /* entered vi command mode at least once */
#define RL_STATE_REDISPLAYING 0x0800000 /* updating terminal display */
#define RL_STATE_DONE 0x1000000 /* done; accepted line */
+887
View File
@@ -0,0 +1,887 @@
/* Readline.h -- the names of functions callable from within readline. */
/* Copyright (C) 1987-2009 Free Software Foundation, Inc.
This file is part of the GNU Readline Library (Readline), a library
for reading lines of text with interactive input and history editing.
Readline is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Readline is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Readline. If not, see <http://www.gnu.org/licenses/>.
*/
#if !defined (_READLINE_H_)
#define _READLINE_H_
#ifdef __cplusplus
extern "C" {
#endif
#if defined (READLINE_LIBRARY)
# include "rlstdc.h"
# include "rltypedefs.h"
# include "keymaps.h"
# include "tilde.h"
#else
# include <readline/rlstdc.h>
# include <readline/rltypedefs.h>
# include <readline/keymaps.h>
# include <readline/tilde.h>
#endif
/* Hex-encoded Readline version number. */
#define RL_READLINE_VERSION 0x0600 /* Readline 6.0 */
#define RL_VERSION_MAJOR 6
#define RL_VERSION_MINOR 0
/* Readline data structures. */
/* Maintaining the state of undo. We remember individual deletes and inserts
on a chain of things to do. */
/* The actions that undo knows how to undo. Notice that UNDO_DELETE means
to insert some text, and UNDO_INSERT means to delete some text. I.e.,
the code tells undo what to undo, not how to undo it. */
enum undo_code { UNDO_DELETE, UNDO_INSERT, UNDO_BEGIN, UNDO_END };
/* What an element of THE_UNDO_LIST looks like. */
typedef struct undo_list {
struct undo_list *next;
int start, end; /* Where the change took place. */
char *text; /* The text to insert, if undoing a delete. */
enum undo_code what; /* Delete, Insert, Begin, End. */
} UNDO_LIST;
/* The current undo list for RL_LINE_BUFFER. */
extern UNDO_LIST *rl_undo_list;
/* The data structure for mapping textual names to code addresses. */
typedef struct _funmap {
const char *name;
rl_command_func_t *function;
} FUNMAP;
extern FUNMAP **funmap;
/* **************************************************************** */
/* */
/* Functions available to bind to key sequences */
/* */
/* **************************************************************** */
/* Bindable commands for numeric arguments. */
extern int rl_digit_argument PARAMS((int, int));
extern int rl_universal_argument PARAMS((int, int));
/* Bindable commands for moving the cursor. */
extern int rl_forward_byte PARAMS((int, int));
extern int rl_forward_char PARAMS((int, int));
extern int rl_forward PARAMS((int, int));
extern int rl_backward_byte PARAMS((int, int));
extern int rl_backward_char PARAMS((int, int));
extern int rl_backward PARAMS((int, int));
extern int rl_beg_of_line PARAMS((int, int));
extern int rl_end_of_line PARAMS((int, int));
extern int rl_forward_word PARAMS((int, int));
extern int rl_backward_word PARAMS((int, int));
extern int rl_refresh_line PARAMS((int, int));
extern int rl_clear_screen PARAMS((int, int));
extern int rl_skip_csi_sequence PARAMS((int, int));
extern int rl_arrow_keys PARAMS((int, int));
/* Bindable commands for inserting and deleting text. */
extern int rl_insert PARAMS((int, int));
extern int rl_quoted_insert PARAMS((int, int));
extern int rl_tab_insert PARAMS((int, int));
extern int rl_newline PARAMS((int, int));
extern int rl_do_lowercase_version PARAMS((int, int));
extern int rl_rubout PARAMS((int, int));
extern int rl_delete PARAMS((int, int));
extern int rl_rubout_or_delete PARAMS((int, int));
extern int rl_delete_horizontal_space PARAMS((int, int));
extern int rl_delete_or_show_completions PARAMS((int, int));
extern int rl_insert_comment PARAMS((int, int));
/* Bindable commands for changing case. */
extern int rl_upcase_word PARAMS((int, int));
extern int rl_downcase_word PARAMS((int, int));
extern int rl_capitalize_word PARAMS((int, int));
/* Bindable commands for transposing characters and words. */
extern int rl_transpose_words PARAMS((int, int));
extern int rl_transpose_chars PARAMS((int, int));
/* Bindable commands for searching within a line. */
extern int rl_char_search PARAMS((int, int));
extern int rl_backward_char_search PARAMS((int, int));
/* Bindable commands for readline's interface to the command history. */
extern int rl_beginning_of_history PARAMS((int, int));
extern int rl_end_of_history PARAMS((int, int));
extern int rl_get_next_history PARAMS((int, int));
extern int rl_get_previous_history PARAMS((int, int));
/* Bindable commands for managing the mark and region. */
extern int rl_set_mark PARAMS((int, int));
extern int rl_exchange_point_and_mark PARAMS((int, int));
/* Bindable commands to set the editing mode (emacs or vi). */
extern int rl_vi_editing_mode PARAMS((int, int));
extern int rl_emacs_editing_mode PARAMS((int, int));
/* Bindable commands to change the insert mode (insert or overwrite) */
extern int rl_overwrite_mode PARAMS((int, int));
/* Bindable commands for managing key bindings. */
extern int rl_re_read_init_file PARAMS((int, int));
extern int rl_dump_functions PARAMS((int, int));
extern int rl_dump_macros PARAMS((int, int));
extern int rl_dump_variables PARAMS((int, int));
/* Bindable commands for word completion. */
extern int rl_complete PARAMS((int, int));
extern int rl_possible_completions PARAMS((int, int));
extern int rl_insert_completions PARAMS((int, int));
extern int rl_old_menu_complete PARAMS((int, int));
extern int rl_menu_complete PARAMS((int, int));
extern int rl_backward_menu_complete PARAMS((int, int));
/* Bindable commands for killing and yanking text, and managing the kill ring. */
extern int rl_kill_word PARAMS((int, int));
extern int rl_backward_kill_word PARAMS((int, int));
extern int rl_kill_line PARAMS((int, int));
extern int rl_backward_kill_line PARAMS((int, int));
extern int rl_kill_full_line PARAMS((int, int));
extern int rl_unix_word_rubout PARAMS((int, int));
extern int rl_unix_filename_rubout PARAMS((int, int));
extern int rl_unix_line_discard PARAMS((int, int));
extern int rl_copy_region_to_kill PARAMS((int, int));
extern int rl_kill_region PARAMS((int, int));
extern int rl_copy_forward_word PARAMS((int, int));
extern int rl_copy_backward_word PARAMS((int, int));
extern int rl_yank PARAMS((int, int));
extern int rl_yank_pop PARAMS((int, int));
extern int rl_yank_nth_arg PARAMS((int, int));
extern int rl_yank_last_arg PARAMS((int, int));
/* Not available unless __CYGWIN__ is defined. */
#ifdef __CYGWIN__
extern int rl_paste_from_clipboard PARAMS((int, int));
#endif
/* Bindable commands for incremental searching. */
extern int rl_reverse_search_history PARAMS((int, int));
extern int rl_forward_search_history PARAMS((int, int));
/* Bindable keyboard macro commands. */
extern int rl_start_kbd_macro PARAMS((int, int));
extern int rl_end_kbd_macro PARAMS((int, int));
extern int rl_call_last_kbd_macro PARAMS((int, int));
/* Bindable undo commands. */
extern int rl_revert_line PARAMS((int, int));
extern int rl_undo_command PARAMS((int, int));
/* Bindable tilde expansion commands. */
extern int rl_tilde_expand PARAMS((int, int));
/* Bindable terminal control commands. */
extern int rl_restart_output PARAMS((int, int));
extern int rl_stop_output PARAMS((int, int));
/* Miscellaneous bindable commands. */
extern int rl_abort PARAMS((int, int));
extern int rl_tty_status PARAMS((int, int));
/* Bindable commands for incremental and non-incremental history searching. */
extern int rl_history_search_forward PARAMS((int, int));
extern int rl_history_search_backward PARAMS((int, int));
extern int rl_noninc_forward_search PARAMS((int, int));
extern int rl_noninc_reverse_search PARAMS((int, int));
extern int rl_noninc_forward_search_again PARAMS((int, int));
extern int rl_noninc_reverse_search_again PARAMS((int, int));
/* Bindable command used when inserting a matching close character. */
extern int rl_insert_close PARAMS((int, int));
/* Not available unless READLINE_CALLBACKS is defined. */
extern void rl_callback_handler_install PARAMS((const char *, rl_vcpfunc_t *));
extern void rl_callback_read_char PARAMS((void));
extern void rl_callback_handler_remove PARAMS((void));
/* Things for vi mode. Not available unless readline is compiled -DVI_MODE. */
/* VI-mode bindable commands. */
extern int rl_vi_redo PARAMS((int, int));
extern int rl_vi_undo PARAMS((int, int));
extern int rl_vi_yank_arg PARAMS((int, int));
extern int rl_vi_fetch_history PARAMS((int, int));
extern int rl_vi_search_again PARAMS((int, int));
extern int rl_vi_search PARAMS((int, int));
extern int rl_vi_complete PARAMS((int, int));
extern int rl_vi_tilde_expand PARAMS((int, int));
extern int rl_vi_prev_word PARAMS((int, int));
extern int rl_vi_next_word PARAMS((int, int));
extern int rl_vi_end_word PARAMS((int, int));
extern int rl_vi_insert_beg PARAMS((int, int));
extern int rl_vi_append_mode PARAMS((int, int));
extern int rl_vi_append_eol PARAMS((int, int));
extern int rl_vi_eof_maybe PARAMS((int, int));
extern int rl_vi_insertion_mode PARAMS((int, int));
extern int rl_vi_insert_mode PARAMS((int, int));
extern int rl_vi_movement_mode PARAMS((int, int));
extern int rl_vi_arg_digit PARAMS((int, int));
extern int rl_vi_change_case PARAMS((int, int));
extern int rl_vi_put PARAMS((int, int));
extern int rl_vi_column PARAMS((int, int));
extern int rl_vi_delete_to PARAMS((int, int));
extern int rl_vi_change_to PARAMS((int, int));
extern int rl_vi_yank_to PARAMS((int, int));
extern int rl_vi_rubout PARAMS((int, int));
extern int rl_vi_delete PARAMS((int, int));
extern int rl_vi_back_to_indent PARAMS((int, int));
extern int rl_vi_first_print PARAMS((int, int));
extern int rl_vi_char_search PARAMS((int, int));
extern int rl_vi_match PARAMS((int, int));
extern int rl_vi_change_char PARAMS((int, int));
extern int rl_vi_subst PARAMS((int, int));
extern int rl_vi_overstrike PARAMS((int, int));
extern int rl_vi_overstrike_delete PARAMS((int, int));
extern int rl_vi_replace PARAMS((int, int));
extern int rl_vi_set_mark PARAMS((int, int));
extern int rl_vi_goto_mark PARAMS((int, int));
/* VI-mode utility functions. */
extern int rl_vi_check PARAMS((void));
extern int rl_vi_domove PARAMS((int, int *));
extern int rl_vi_bracktype PARAMS((int));
extern void rl_vi_start_inserting PARAMS((int, int, int));
/* VI-mode pseudo-bindable commands, used as utility functions. */
extern int rl_vi_fWord PARAMS((int, int));
extern int rl_vi_bWord PARAMS((int, int));
extern int rl_vi_eWord PARAMS((int, int));
extern int rl_vi_fword PARAMS((int, int));
extern int rl_vi_bword PARAMS((int, int));
extern int rl_vi_eword PARAMS((int, int));
/* **************************************************************** */
/* */
/* Well Published Functions */
/* */
/* **************************************************************** */
/* Readline functions. */
/* Read a line of input. Prompt with PROMPT. A NULL PROMPT means none. */
extern char *readline PARAMS((const char *));
extern int rl_set_prompt PARAMS((const char *));
extern int rl_expand_prompt PARAMS((char *));
extern int rl_initialize PARAMS((void));
/* Undocumented; unused by readline */
extern int rl_discard_argument PARAMS((void));
/* Utility functions to bind keys to readline commands. */
extern int rl_add_defun PARAMS((const char *, rl_command_func_t *, int));
extern int rl_bind_key PARAMS((int, rl_command_func_t *));
extern int rl_bind_key_in_map PARAMS((int, rl_command_func_t *, Keymap));
extern int rl_unbind_key PARAMS((int));
extern int rl_unbind_key_in_map PARAMS((int, Keymap));
extern int rl_bind_key_if_unbound PARAMS((int, rl_command_func_t *));
extern int rl_bind_key_if_unbound_in_map PARAMS((int, rl_command_func_t *, Keymap));
extern int rl_unbind_function_in_map PARAMS((rl_command_func_t *, Keymap));
extern int rl_unbind_command_in_map PARAMS((const char *, Keymap));
extern int rl_bind_keyseq PARAMS((const char *, rl_command_func_t *));
extern int rl_bind_keyseq_in_map PARAMS((const char *, rl_command_func_t *, Keymap));
extern int rl_bind_keyseq_if_unbound PARAMS((const char *, rl_command_func_t *));
extern int rl_bind_keyseq_if_unbound_in_map PARAMS((const char *, rl_command_func_t *, Keymap));
extern int rl_generic_bind PARAMS((int, const char *, char *, Keymap));
extern char *rl_variable_value PARAMS((const char *));
extern int rl_variable_bind PARAMS((const char *, const char *));
/* Backwards compatibility, use rl_bind_keyseq_in_map instead. */
extern int rl_set_key PARAMS((const char *, rl_command_func_t *, Keymap));
/* Backwards compatibility, use rl_generic_bind instead. */
extern int rl_macro_bind PARAMS((const char *, const char *, Keymap));
/* Undocumented in the texinfo manual; not really useful to programs. */
extern int rl_translate_keyseq PARAMS((const char *, char *, int *));
extern char *rl_untranslate_keyseq PARAMS((int));
extern rl_command_func_t *rl_named_function PARAMS((const char *));
extern rl_command_func_t *rl_function_of_keyseq PARAMS((const char *, Keymap, int *));
extern void rl_list_funmap_names PARAMS((void));
extern char **rl_invoking_keyseqs_in_map PARAMS((rl_command_func_t *, Keymap));
extern char **rl_invoking_keyseqs PARAMS((rl_command_func_t *));
extern void rl_function_dumper PARAMS((int));
extern void rl_macro_dumper PARAMS((int));
extern void rl_variable_dumper PARAMS((int));
extern int rl_read_init_file PARAMS((const char *));
extern int rl_parse_and_bind PARAMS((char *));
/* Functions for manipulating keymaps. */
extern Keymap rl_make_bare_keymap PARAMS((void));
extern Keymap rl_copy_keymap PARAMS((Keymap));
extern Keymap rl_make_keymap PARAMS((void));
extern void rl_discard_keymap PARAMS((Keymap));
extern Keymap rl_get_keymap_by_name PARAMS((const char *));
extern char *rl_get_keymap_name PARAMS((Keymap));
extern void rl_set_keymap PARAMS((Keymap));
extern Keymap rl_get_keymap PARAMS((void));
/* Undocumented; used internally only. */
extern void rl_set_keymap_from_edit_mode PARAMS((void));
extern char *rl_get_keymap_name_from_edit_mode PARAMS((void));
/* Functions for manipulating the funmap, which maps command names to functions. */
extern int rl_add_funmap_entry PARAMS((const char *, rl_command_func_t *));
extern const char **rl_funmap_names PARAMS((void));
/* Undocumented, only used internally -- there is only one funmap, and this
function may be called only once. */
extern void rl_initialize_funmap PARAMS((void));
/* Utility functions for managing keyboard macros. */
extern void rl_push_macro_input PARAMS((char *));
/* Functions for undoing, from undo.c */
extern void rl_add_undo PARAMS((enum undo_code, int, int, char *));
extern void rl_free_undo_list PARAMS((void));
extern int rl_do_undo PARAMS((void));
extern int rl_begin_undo_group PARAMS((void));
extern int rl_end_undo_group PARAMS((void));
extern int rl_modifying PARAMS((int, int));
/* Functions for redisplay. */
extern void rl_redisplay PARAMS((void));
extern int rl_on_new_line PARAMS((void));
extern int rl_on_new_line_with_prompt PARAMS((void));
extern int rl_forced_update_display PARAMS((void));
extern int rl_clear_message PARAMS((void));
extern int rl_reset_line_state PARAMS((void));
extern int rl_crlf PARAMS((void));
#if defined (USE_VARARGS) && defined (PREFER_STDARG)
extern int rl_message (const char *, ...) __attribute__((__format__ (printf, 1, 2)));
#else
extern int rl_message ();
#endif
extern int rl_show_char PARAMS((int));
/* Undocumented in texinfo manual. */
extern int rl_character_len PARAMS((int, int));
/* Save and restore internal prompt redisplay information. */
extern void rl_save_prompt PARAMS((void));
extern void rl_restore_prompt PARAMS((void));
/* Modifying text. */
extern void rl_replace_line PARAMS((const char *, int));
extern int rl_insert_text PARAMS((const char *));
extern int rl_delete_text PARAMS((int, int));
extern int rl_kill_text PARAMS((int, int));
extern char *rl_copy_text PARAMS((int, int));
/* Terminal and tty mode management. */
extern void rl_prep_terminal PARAMS((int));
extern void rl_deprep_terminal PARAMS((void));
extern void rl_tty_set_default_bindings PARAMS((Keymap));
extern void rl_tty_unset_default_bindings PARAMS((Keymap));
extern int rl_reset_terminal PARAMS((const char *));
extern void rl_resize_terminal PARAMS((void));
extern void rl_set_screen_size PARAMS((int, int));
extern void rl_get_screen_size PARAMS((int *, int *));
extern void rl_reset_screen_size PARAMS((void));
extern char *rl_get_termcap PARAMS((const char *));
/* Functions for character input. */
extern int rl_stuff_char PARAMS((int));
extern int rl_execute_next PARAMS((int));
extern int rl_clear_pending_input PARAMS((void));
extern int rl_read_key PARAMS((void));
extern int rl_getc PARAMS((FILE *));
extern int rl_set_keyboard_input_timeout PARAMS((int));
/* `Public' utility functions . */
extern void rl_extend_line_buffer PARAMS((int));
extern int rl_ding PARAMS((void));
extern int rl_alphabetic PARAMS((int));
extern void rl_free PARAMS((void *));
/* Readline signal handling, from signals.c */
extern int rl_set_signals PARAMS((void));
extern int rl_clear_signals PARAMS((void));
extern void rl_cleanup_after_signal PARAMS((void));
extern void rl_reset_after_signal PARAMS((void));
extern void rl_free_line_state PARAMS((void));
extern void rl_echo_signal_char PARAMS((int));
extern int rl_set_paren_blink_timeout PARAMS((int));
/* Undocumented. */
extern int rl_maybe_save_line PARAMS((void));
extern int rl_maybe_unsave_line PARAMS((void));
extern int rl_maybe_replace_line PARAMS((void));
/* Completion functions. */
extern int rl_complete_internal PARAMS((int));
extern void rl_display_match_list PARAMS((char **, int, int));
extern char **rl_completion_matches PARAMS((const char *, rl_compentry_func_t *));
extern char *rl_username_completion_function PARAMS((const char *, int));
extern char *rl_filename_completion_function PARAMS((const char *, int));
extern int rl_completion_mode PARAMS((rl_command_func_t *));
#if 0
/* Backwards compatibility (compat.c). These will go away sometime. */
extern void free_undo_list PARAMS((void));
extern int maybe_save_line PARAMS((void));
extern int maybe_unsave_line PARAMS((void));
extern int maybe_replace_line PARAMS((void));
extern int ding PARAMS((void));
extern int alphabetic PARAMS((int));
extern int crlf PARAMS((void));
extern char **completion_matches PARAMS((char *, rl_compentry_func_t *));
extern char *username_completion_function PARAMS((const char *, int));
extern char *filename_completion_function PARAMS((const char *, int));
#endif
/* **************************************************************** */
/* */
/* Well Published Variables */
/* */
/* **************************************************************** */
/* The version of this incarnation of the readline library. */
extern const char *rl_library_version; /* e.g., "4.2" */
extern int rl_readline_version; /* e.g., 0x0402 */
/* True if this is real GNU readline. */
extern int rl_gnu_readline_p;
/* Flags word encapsulating the current readline state. */
extern int rl_readline_state;
/* Says which editing mode readline is currently using. 1 means emacs mode;
0 means vi mode. */
extern int rl_editing_mode;
/* Insert or overwrite mode for emacs mode. 1 means insert mode; 0 means
overwrite mode. Reset to insert mode on each input line. */
extern int rl_insert_mode;
/* The name of the calling program. You should initialize this to
whatever was in argv[0]. It is used when parsing conditionals. */
extern const char *rl_readline_name;
/* The prompt readline uses. This is set from the argument to
readline (), and should not be assigned to directly. */
extern char *rl_prompt;
/* The prompt string that is actually displayed by rl_redisplay. Public so
applications can more easily supply their own redisplay functions. */
extern char *rl_display_prompt;
/* The line buffer that is in use. */
extern char *rl_line_buffer;
/* The location of point, and end. */
extern int rl_point;
extern int rl_end;
/* The mark, or saved cursor position. */
extern int rl_mark;
/* Flag to indicate that readline has finished with the current input
line and should return it. */
extern int rl_done;
/* If set to a character value, that will be the next keystroke read. */
extern int rl_pending_input;
/* Non-zero if we called this function from _rl_dispatch(). It's present
so functions can find out whether they were called from a key binding
or directly from an application. */
extern int rl_dispatching;
/* Non-zero if the user typed a numeric argument before executing the
current function. */
extern int rl_explicit_arg;
/* The current value of the numeric argument specified by the user. */
extern int rl_numeric_arg;
/* The address of the last command function Readline executed. */
extern rl_command_func_t *rl_last_func;
/* The name of the terminal to use. */
extern const char *rl_terminal_name;
/* The input and output streams. */
extern FILE *rl_instream;
extern FILE *rl_outstream;
/* If non-zero, Readline gives values of LINES and COLUMNS from the environment
greater precedence than values fetched from the kernel when computing the
screen dimensions. */
extern int rl_prefer_env_winsize;
/* If non-zero, then this is the address of a function to call just
before readline_internal () prints the first prompt. */
extern rl_hook_func_t *rl_startup_hook;
/* If non-zero, this is the address of a function to call just before
readline_internal_setup () returns and readline_internal starts
reading input characters. */
extern rl_hook_func_t *rl_pre_input_hook;
/* The address of a function to call periodically while Readline is
awaiting character input, or NULL, for no event handling. */
extern rl_hook_func_t *rl_event_hook;
/* The address of the function to call to fetch a character from the current
Readline input stream */
extern rl_getc_func_t *rl_getc_function;
extern rl_voidfunc_t *rl_redisplay_function;
extern rl_vintfunc_t *rl_prep_term_function;
extern rl_voidfunc_t *rl_deprep_term_function;
/* Dispatch variables. */
extern Keymap rl_executing_keymap;
extern Keymap rl_binding_keymap;
/* Display variables. */
/* If non-zero, readline will erase the entire line, including any prompt,
if the only thing typed on an otherwise-blank line is something bound to
rl_newline. */
extern int rl_erase_empty_line;
/* If non-zero, the application has already printed the prompt (rl_prompt)
before calling readline, so readline should not output it the first time
redisplay is done. */
extern int rl_already_prompted;
/* A non-zero value means to read only this many characters rather than
up to a character bound to accept-line. */
extern int rl_num_chars_to_read;
/* The text of a currently-executing keyboard macro. */
extern char *rl_executing_macro;
/* Variables to control readline signal handling. */
/* If non-zero, readline will install its own signal handlers for
SIGINT, SIGTERM, SIGQUIT, SIGALRM, SIGTSTP, SIGTTIN, and SIGTTOU. */
extern int rl_catch_signals;
/* If non-zero, readline will install a signal handler for SIGWINCH
that also attempts to call any calling application's SIGWINCH signal
handler. Note that the terminal is not cleaned up before the
application's signal handler is called; use rl_cleanup_after_signal()
to do that. */
extern int rl_catch_sigwinch;
/* Completion variables. */
/* Pointer to the generator function for completion_matches ().
NULL means to use rl_filename_completion_function (), the default
filename completer. */
extern rl_compentry_func_t *rl_completion_entry_function;
/* Optional generator for menu completion. Default is
rl_completion_entry_function (rl_filename_completion_function). */
extern rl_compentry_func_t *rl_menu_completion_entry_function;
/* If rl_ignore_some_completions_function is non-NULL it is the address
of a function to call after all of the possible matches have been
generated, but before the actual completion is done to the input line.
The function is called with one argument; a NULL terminated array
of (char *). If your function removes any of the elements, they
must be free()'ed. */
extern rl_compignore_func_t *rl_ignore_some_completions_function;
/* Pointer to alternative function to create matches.
Function is called with TEXT, START, and END.
START and END are indices in RL_LINE_BUFFER saying what the boundaries
of TEXT are.
If this function exists and returns NULL then call the value of
rl_completion_entry_function to try to match, otherwise use the
array of strings returned. */
extern rl_completion_func_t *rl_attempted_completion_function;
/* The basic list of characters that signal a break between words for the
completer routine. The initial contents of this variable is what
breaks words in the shell, i.e. "n\"\\'`@$>". */
extern const char *rl_basic_word_break_characters;
/* The list of characters that signal a break between words for
rl_complete_internal. The default list is the contents of
rl_basic_word_break_characters. */
extern /*const*/ char *rl_completer_word_break_characters;
/* Hook function to allow an application to set the completion word
break characters before readline breaks up the line. Allows
position-dependent word break characters. */
extern rl_cpvfunc_t *rl_completion_word_break_hook;
/* List of characters which can be used to quote a substring of the line.
Completion occurs on the entire substring, and within the substring
rl_completer_word_break_characters are treated as any other character,
unless they also appear within this list. */
extern const char *rl_completer_quote_characters;
/* List of quote characters which cause a word break. */
extern const char *rl_basic_quote_characters;
/* List of characters that need to be quoted in filenames by the completer. */
extern const char *rl_filename_quote_characters;
/* List of characters that are word break characters, but should be left
in TEXT when it is passed to the completion function. The shell uses
this to help determine what kind of completing to do. */
extern const char *rl_special_prefixes;
/* If non-zero, then this is the address of a function to call when
completing on a directory name. The function is called with
the address of a string (the current directory name) as an arg. It
changes what is displayed when the possible completions are printed
or inserted. */
extern rl_icppfunc_t *rl_directory_completion_hook;
/* If non-zero, this is the address of a function to call when completing
a directory name. This function takes the address of the directory name
to be modified as an argument. Unlike rl_directory_completion_hook, it
only modifies the directory name used in opendir(2), not what is displayed
when the possible completions are printed or inserted. It is called
before rl_directory_completion_hook. I'm not happy with how this works
yet, so it's undocumented. */
extern rl_icppfunc_t *rl_directory_rewrite_hook;
/* If non-zero, this is the address of a function to call when reading
directory entries from the filesystem for completion and comparing
them to the partial word to be completed. The function should
either return its first argument (if no conversion takes place) or
newly-allocated memory. This can, for instance, convert filenames
between character sets for comparison against what's typed at the
keyboard. The returned value is what is added to the list of
matches. The second argument is the length of the filename to be
converted. */
extern rl_dequote_func_t *rl_filename_rewrite_hook;
/* Backwards compatibility with previous versions of readline. */
#define rl_symbolic_link_hook rl_directory_completion_hook
/* If non-zero, then this is the address of a function to call when
completing a word would normally display the list of possible matches.
This function is called instead of actually doing the display.
It takes three arguments: (char **matches, int num_matches, int max_length)
where MATCHES is the array of strings that matched, NUM_MATCHES is the
number of strings in that array, and MAX_LENGTH is the length of the
longest string in that array. */
extern rl_compdisp_func_t *rl_completion_display_matches_hook;
/* Non-zero means that the results of the matches are to be treated
as filenames. This is ALWAYS zero on entry, and can only be changed
within a completion entry finder function. */
extern int rl_filename_completion_desired;
/* Non-zero means that the results of the matches are to be quoted using
double quotes (or an application-specific quoting mechanism) if the
filename contains any characters in rl_word_break_chars. This is
ALWAYS non-zero on entry, and can only be changed within a completion
entry finder function. */
extern int rl_filename_quoting_desired;
/* Set to a function to quote a filename in an application-specific fashion.
Called with the text to quote, the type of match found (single or multiple)
and a pointer to the quoting character to be used, which the function can
reset if desired. */
extern rl_quote_func_t *rl_filename_quoting_function;
/* Function to call to remove quoting characters from a filename. Called
before completion is attempted, so the embedded quotes do not interfere
with matching names in the file system. */
extern rl_dequote_func_t *rl_filename_dequoting_function;
/* Function to call to decide whether or not a word break character is
quoted. If a character is quoted, it does not break words for the
completer. */
extern rl_linebuf_func_t *rl_char_is_quoted_p;
/* Non-zero means to suppress normal filename completion after the
user-specified completion function has been called. */
extern int rl_attempted_completion_over;
/* Set to a character describing the type of completion being attempted by
rl_complete_internal; available for use by application completion
functions. */
extern int rl_completion_type;
/* Set to the last key used to invoke one of the completion functions */
extern int rl_completion_invoking_key;
/* Up to this many items will be displayed in response to a
possible-completions call. After that, we ask the user if she
is sure she wants to see them all. The default value is 100. */
extern int rl_completion_query_items;
/* Character appended to completed words when at the end of the line. The
default is a space. Nothing is added if this is '\0'. */
extern int rl_completion_append_character;
/* If set to non-zero by an application completion function,
rl_completion_append_character will not be appended. */
extern int rl_completion_suppress_append;
/* Set to any quote character readline thinks it finds before any application
completion function is called. */
extern int rl_completion_quote_character;
/* Set to a non-zero value if readline found quoting anywhere in the word to
be completed; set before any application completion function is called. */
extern int rl_completion_found_quote;
/* If non-zero, the completion functions don't append any closing quote.
This is set to 0 by rl_complete_internal and may be changed by an
application-specific completion function. */
extern int rl_completion_suppress_quote;
/* If non-zero, readline will sort the completion matches. On by default. */
extern int rl_sort_completion_matches;
/* If non-zero, a slash will be appended to completed filenames that are
symbolic links to directory names, subject to the value of the
mark-directories variable (which is user-settable). This exists so
that application completion functions can override the user's preference
(set via the mark-symlinked-directories variable) if appropriate.
It's set to the value of _rl_complete_mark_symlink_dirs in
rl_complete_internal before any application-specific completion
function is called, so without that function doing anything, the user's
preferences are honored. */
extern int rl_completion_mark_symlink_dirs;
/* If non-zero, then disallow duplicates in the matches. */
extern int rl_ignore_completion_duplicates;
/* If this is non-zero, completion is (temporarily) inhibited, and the
completion character will be inserted as any other. */
extern int rl_inhibit_completion;
/* Input error; can be returned by (*rl_getc_function) if readline is reading
a top-level command (RL_ISSTATE (RL_STATE_READCMD)). */
#define READERR (-2)
/* Definitions available for use by readline clients. */
#define RL_PROMPT_START_IGNORE '\001'
#define RL_PROMPT_END_IGNORE '\002'
/* Possible values for do_replace argument to rl_filename_quoting_function,
called by rl_complete_internal. */
#define NO_MATCH 0
#define SINGLE_MATCH 1
#define MULT_MATCH 2
/* Possible state values for rl_readline_state */
#define RL_STATE_NONE 0x000000 /* no state; before first call */
#define RL_STATE_INITIALIZING 0x0000001 /* initializing */
#define RL_STATE_INITIALIZED 0x0000002 /* initialization done */
#define RL_STATE_TERMPREPPED 0x0000004 /* terminal is prepped */
#define RL_STATE_READCMD 0x0000008 /* reading a command key */
#define RL_STATE_METANEXT 0x0000010 /* reading input after ESC */
#define RL_STATE_DISPATCHING 0x0000020 /* dispatching to a command */
#define RL_STATE_MOREINPUT 0x0000040 /* reading more input in a command function */
#define RL_STATE_ISEARCH 0x0000080 /* doing incremental search */
#define RL_STATE_NSEARCH 0x0000100 /* doing non-inc search */
#define RL_STATE_SEARCH 0x0000200 /* doing a history search */
#define RL_STATE_NUMERICARG 0x0000400 /* reading numeric argument */
#define RL_STATE_MACROINPUT 0x0000800 /* getting input from a macro */
#define RL_STATE_MACRODEF 0x0001000 /* defining keyboard macro */
#define RL_STATE_OVERWRITE 0x0002000 /* overwrite mode */
#define RL_STATE_COMPLETING 0x0004000 /* doing completion */
#define RL_STATE_SIGHANDLER 0x0008000 /* in readline sighandler */
#define RL_STATE_UNDOING 0x0010000 /* doing an undo */
#define RL_STATE_INPUTPENDING 0x0020000 /* rl_execute_next called */
#define RL_STATE_TTYCSAVED 0x0040000 /* tty special chars saved */
#define RL_STATE_CALLBACK 0x0080000 /* using the callback interface */
#define RL_STATE_VIMOTION 0x0100000 /* reading vi motion arg */
#define RL_STATE_MULTIKEY 0x0200000 /* reading multiple-key command */
#define RL_STATE_VICMDONCE 0x0400000 /* entered vi command mode at least once */
#define RL_STATE_REDISPLAYING 0x0800000 /* updating terminal display */
#define RL_STATE_VIMOVECHAR 0x1000000 /* vi motion compound command motion char*/
#define RL_STATE_VIMOVEDIGIT 0x2000000 /* vi motion command numeric arg */
#define RL_STATE_DONE 0x10000000 /* done; accepted line */
#define RL_SETSTATE(x) (rl_readline_state |= (x))
#define RL_UNSETSTATE(x) (rl_readline_state &= ~(x))
#define RL_ISSTATE(x) (rl_readline_state & (x))
struct readline_state {
/* line state */
int point;
int end;
int mark;
char *buffer;
int buflen;
UNDO_LIST *ul;
char *prompt;
/* global state */
int rlstate;
int done;
Keymap kmap;
/* input state */
rl_command_func_t *lastfunc;
int insmode;
int edmode;
int kseqlen;
FILE *inf;
FILE *outf;
int pendingin;
char *macro;
/* signal state */
int catchsigs;
int catchsigwinch;
/* search state */
/* completion state */
/* options state */
/* reserved for future expansion, so the struct size doesn't change */
char reserved[64];
};
extern int rl_save_state PARAMS((struct readline_state *));
extern int rl_restore_state PARAMS((struct readline_state *));
#ifdef __cplusplus
}
#endif
#endif /* _READLINE_H_ */
+2
View File
@@ -387,6 +387,7 @@ extern void _rl_vi_reset_last PARAMS((void));
extern void _rl_vi_set_last PARAMS((int, int, int));
extern int _rl_vi_textmod_command PARAMS((int));
extern void _rl_vi_done_inserting PARAMS((void));
extern int _rl_vi_domove_callback PARAMS((_rl_vimotion_cxt *));
/*************************************************************************
* Undocumented private variables *
@@ -494,5 +495,6 @@ extern int _rl_undo_group_level;
/* vi_mode.c */
extern int _rl_vi_last_command;
extern _rl_vimotion_cxt *_rl_vimvcxt;
#endif /* _RL_PRIVATE_H_ */
+7
View File
@@ -125,6 +125,11 @@ typedef struct __rl_keyseq_context
#define VIM_CHANGE 0x02
#define VIM_YANK 0x04
/* various states for vi-mode commands that use motion commands. reflects
RL_READLINE_STATE */
#define VMSTATE_READ 0x01
#define VMSTATE_NUMARG 0x02
typedef struct __rl_vimotion_context
{
int op;
@@ -382,6 +387,7 @@ extern void _rl_vi_reset_last PARAMS((void));
extern void _rl_vi_set_last PARAMS((int, int, int));
extern int _rl_vi_textmod_command PARAMS((int));
extern void _rl_vi_done_inserting PARAMS((void));
extern int _rl_vi_domove_callback PARAMS((_rl_vimotion_cxt *));
/*************************************************************************
* Undocumented private variables *
@@ -489,5 +495,6 @@ extern int _rl_undo_group_level;
/* vi_mode.c */
extern int _rl_vi_last_command;
extern _rl_vimotion_cxt *_rl_vimv_cxt;
#endif /* _RL_PRIVATE_H_ */
+260 -151
View File
@@ -130,6 +130,10 @@ static int _rl_vi_callback_change_char PARAMS((_rl_callback_generic_arg *));
static int _rl_vi_callback_char_search PARAMS((_rl_callback_generic_arg *));
#endif
static int rl_domove_read_callback PARAMS((_rl_vimotion_cxt *));
static int rl_domove_motion_callback PARAMS((_rl_vimotion_cxt *));
static int rl_vi_domove_getchar PARAMS((_rl_vimotion_cxt *));
static int vi_change_dispatch PARAMS((_rl_vimotion_cxt *));
static int vi_delete_dispatch PARAMS((_rl_vimotion_cxt *));
static int vi_yank_dispatch PARAMS((_rl_vimotion_cxt *));
@@ -918,113 +922,6 @@ rl_vi_column (count, key)
return (0);
}
int
rl_vi_domove (key, nextkey)
int key, *nextkey;
{
int c, save;
int old_end;
rl_mark = rl_point;
RL_SETSTATE(RL_STATE_MOREINPUT);
c = rl_read_key ();
RL_UNSETSTATE(RL_STATE_MOREINPUT);
if (c < 0)
{
*nextkey = 0;
return -1;
}
*nextkey = c;
if (!member (c, vi_motion))
{
if (_rl_digit_p (c))
{
save = rl_numeric_arg;
rl_numeric_arg = _rl_digit_value (c);
rl_explicit_arg = 1;
RL_SETSTATE (RL_STATE_NUMERICARG|RL_STATE_VIMOTION);
rl_digit_loop1 ();
RL_UNSETSTATE (RL_STATE_VIMOTION);
rl_numeric_arg *= save;
RL_SETSTATE(RL_STATE_MOREINPUT);
c = rl_read_key (); /* real command */
RL_UNSETSTATE(RL_STATE_MOREINPUT);
if (c < 0)
{
*nextkey = 0;
return -1;
}
*nextkey = c;
}
else if (key == c && (key == 'd' || key == 'y' || key == 'c'))
{
rl_mark = rl_end;
rl_beg_of_line (1, c);
_rl_vi_last_motion = c;
return (0);
}
else
return (-1);
}
_rl_vi_last_motion = c;
/* Append a blank character temporarily so that the motion routines
work right at the end of the line. */
old_end = rl_end;
rl_line_buffer[rl_end++] = ' ';
rl_line_buffer[rl_end] = '\0';
_rl_dispatch (c, _rl_keymap);
/* Remove the blank that we added. */
rl_end = old_end;
rl_line_buffer[rl_end] = '\0';
if (rl_point > rl_end)
rl_point = rl_end;
/* No change in position means the command failed. */
if (rl_mark == rl_point)
return (-1);
/* rl_vi_f[wW]ord () leaves the cursor on the first character of the next
word. If we are not at the end of the line, and we are on a
non-whitespace character, move back one (presumably to whitespace). */
if ((_rl_to_upper (c) == 'W') && rl_point < rl_end && rl_point > rl_mark &&
!whitespace (rl_line_buffer[rl_point]))
rl_point--;
/* If cw or cW, back up to the end of a word, so the behaviour of ce
or cE is the actual result. Brute-force, no subtlety. */
if (key == 'c' && rl_point >= rl_mark && (_rl_to_upper (c) == 'W'))
{
/* Don't move farther back than where we started. */
while (rl_point > rl_mark && whitespace (rl_line_buffer[rl_point]))
rl_point--;
/* Posix.2 says that if cw or cW moves the cursor towards the end of
the line, the character under the cursor should be deleted. */
if (rl_point == rl_mark)
rl_point++;
else
{
/* Move past the end of the word so that the kill doesn't
remove the last letter of the previous word. Only do this
if we are not at the end of the line. */
if (rl_point >= 0 && rl_point < (rl_end - 1) && !whitespace (rl_line_buffer[rl_point]))
rl_point++;
}
}
if (rl_mark < rl_point)
SWAP (rl_point, rl_mark);
return (0);
}
/* Process C as part of the current numeric argument. Return -1 if the
argument should be aborted, 0 if we should not read any more chars, and
1 if we should continue to read chars. */
@@ -1050,13 +947,13 @@ _rl_vi_arg_dispatch (c)
else
rl_numeric_arg = _rl_digit_value (c);
rl_explicit_arg = 1;
return 1;
return 1; /* keep going */
}
else
{
rl_clear_message ();
rl_stuff_char (key);
return 0;
return 0; /* done */
}
}
@@ -1117,19 +1014,191 @@ _rl_mvcxt_dispose (m)
free (m);
}
/*
* 1. Create context, set initial values
* 2. Pass to rl_vi_domove to populate
* 3. Use returned context to finish rest of command
*
* Context:
* op
* state
* flags
* numeric arg
* start, end positions
* initial key (key), motion key (c)
*/
static int
rl_domove_motion_callback (m)
_rl_vimotion_cxt *m;
{
int c, key, save, r;
int old_end;
_rl_vi_last_motion = c = m->motion;
/* Append a blank character temporarily so that the motion routines
work right at the end of the line. */
old_end = rl_end;
rl_line_buffer[rl_end++] = ' ';
rl_line_buffer[rl_end] = '\0';
_rl_dispatch (c, _rl_keymap);
/* Remove the blank that we added. */
rl_end = old_end;
rl_line_buffer[rl_end] = '\0';
if (rl_point > rl_end)
rl_point = rl_end;
/* No change in position means the command failed. */
if (rl_mark == rl_point)
return (-1);
/* rl_vi_f[wW]ord () leaves the cursor on the first character of the next
word. If we are not at the end of the line, and we are on a
non-whitespace character, move back one (presumably to whitespace). */
if ((_rl_to_upper (c) == 'W') && rl_point < rl_end && rl_point > rl_mark &&
!whitespace (rl_line_buffer[rl_point]))
rl_point--;
/* If cw or cW, back up to the end of a word, so the behaviour of ce
or cE is the actual result. Brute-force, no subtlety. */
if (key == 'c' && rl_point >= rl_mark && (_rl_to_upper (c) == 'W'))
{
/* Don't move farther back than where we started. */
while (rl_point > rl_mark && whitespace (rl_line_buffer[rl_point]))
rl_point--;
/* Posix.2 says that if cw or cW moves the cursor towards the end of
the line, the character under the cursor should be deleted. */
if (rl_point == rl_mark)
rl_point++;
else
{
/* Move past the end of the word so that the kill doesn't
remove the last letter of the previous word. Only do this
if we are not at the end of the line. */
if (rl_point >= 0 && rl_point < (rl_end - 1) && !whitespace (rl_line_buffer[rl_point]))
rl_point++;
}
}
if (rl_mark < rl_point)
SWAP (rl_point, rl_mark);
#if defined (READLINE_CALLBACKS)
if (RL_ISSTATE (RL_STATE_CALLBACK))
(*rl_redisplay_function)(); /* make sure motion is displayed */
#endif
r = vidomove_dispatch (m);
return (r);
}
#define RL_VIMOVENUMARG() (RL_ISSTATE (RL_STATE_VIMOTION) && RL_ISSTATE (RL_STATE_NUMERICARG))
static int
rl_domove_read_callback (m)
_rl_vimotion_cxt *m;
{
int c, save;
c = m->motion;
if (member (c, vi_motion))
{
#if defined (READLINE_CALLBACKS)
/* If we just read a vi-mode motion command numeric argument, turn off
the `reading numeric arg' state */
if (RL_ISSTATE (RL_STATE_CALLBACK) && RL_VIMOVENUMARG())
RL_UNSETSTATE (RL_STATE_NUMERICARG);
#endif
/* Should do everything, including turning off RL_STATE_VIMOTION */
return (rl_domove_motion_callback (m));
}
else if (m->key == c && (m->key == 'd' || m->key == 'y' || m->key == 'c'))
{
rl_mark = rl_end;
rl_beg_of_line (1, c);
_rl_vi_last_motion = c;
RL_UNSETSTATE (RL_STATE_VIMOTION);
return (0);
}
#if defined (READLINE_CALLBACKS)
/* XXX - these need to handle rl_universal_argument bindings */
/* Reading vi motion char continuing numeric argument */
else if (_rl_digit_p (c) && RL_ISSTATE (RL_STATE_CALLBACK) && RL_VIMOVENUMARG())
{
return (_rl_vi_arg_dispatch (c));
}
/* Readine vi motion char starting numeric argument */
else if (_rl_digit_p (c) && RL_ISSTATE (RL_STATE_CALLBACK) && RL_ISSTATE (RL_STATE_VIMOTION) && (RL_ISSTATE (RL_STATE_NUMERICARG) == 0))
{
RL_SETSTATE (RL_STATE_NUMERICARG);
return (_rl_vi_arg_dispatch (c));
}
#endif
else if (_rl_digit_p (c))
{
/* This code path taken when not in callback mode */
save = rl_numeric_arg;
rl_numeric_arg = _rl_digit_value (c);
rl_explicit_arg = 1;
RL_SETSTATE (RL_STATE_NUMERICARG);
rl_digit_loop1 ();
rl_numeric_arg *= save;
c = rl_vi_domove_getchar (m);
if (c < 0)
{
m->motion = 0;
return -1;
}
m->motion = c;
return (rl_domove_motion_callback (m));
}
else
{
RL_UNSETSTATE (RL_STATE_VIMOTION);
RL_UNSETSTATE (RL_STATE_NUMERICARG);
return (1);
}
}
static int
rl_vi_domove_getchar (m)
_rl_vimotion_cxt *m;
{
int c;
RL_SETSTATE(RL_STATE_MOREINPUT);
c = rl_read_key ();
RL_UNSETSTATE(RL_STATE_MOREINPUT);
return c;
}
#if defined (READLINE_CALLBACKS)
int
_rl_vi_domove_callback (m)
_rl_vimotion_cxt *m;
{
int c, r;
m->motion = c = rl_vi_domove_getchar (m);
/* XXX - what to do if this returns -1? Should we return 1 for eof to
callback code? */
r = rl_domove_read_callback (m);
return ((r == 0) ? r : 1); /* normalize return values */
}
#endif
/* This code path taken when not in callback mode. */
int
rl_vi_domove (x, ignore)
int x, *ignore;
{
int r;
_rl_vimotion_cxt *m;
*ignore = m->motion = rl_vi_domove_getchar (m = _rl_vimvcxt);
if (m->motion < 0)
{
m->motion = 0;
return -1;
}
return (rl_domove_read_callback (m));
}
static int
vi_delete_dispatch (m)
@@ -1151,25 +1220,39 @@ rl_vi_delete_to (count, key)
{
int c, r;
if (_rl_uppercase_p (key))
rl_stuff_char ('$');
else if (vi_redoing)
rl_stuff_char (_rl_vi_last_motion);
_rl_vimvcxt = _rl_mvcxt_alloc (VIM_DELETE, key);
_rl_vimvcxt->start = rl_point;
/* XXX -- TODO -- pass and use context in rl_vi_domove */
if (rl_vi_domove (key, &c))
rl_mark = rl_point;
if (_rl_uppercase_p (key))
{
_rl_vimvcxt->motion = '$';
r = rl_domove_motion_callback (_rl_vimvcxt);
}
else if (vi_redoing)
{
_rl_vimvcxt->motion = _rl_vi_last_motion;
r = rl_domove_motion_callback (_rl_vimvcxt);
}
#if defined (READLINE_CALLBACKS)
else if (RL_ISSTATE (RL_STATE_CALLBACK))
{
RL_SETSTATE (RL_STATE_VIMOTION);
return (0);
}
#endif
else
r = rl_vi_domove (key, &c);
if (r < 0)
{
rl_ding ();
return -1;
r = -1;
}
_rl_vimvcxt->motion = c;
r = vidomove_dispatch (_rl_vimvcxt);
_rl_mvcxt_dispose (_rl_vimvcxt);
_rl_vimvcxt = 0;
return r;
}
@@ -1219,25 +1302,39 @@ rl_vi_change_to (count, key)
{
int c, r;
if (_rl_uppercase_p (key))
rl_stuff_char ('$');
else if (vi_redoing)
rl_stuff_char (_rl_vi_last_motion);
_rl_vimvcxt = _rl_mvcxt_alloc (VIM_CHANGE, key);
_rl_vimvcxt->start = rl_point;
/* XXX -- TODO -- pass and use context in rl_vi_domove */
if (rl_vi_domove (key, &c))
rl_mark = rl_point;
if (_rl_uppercase_p (key))
{
_rl_vimvcxt->motion = '$';
r = rl_domove_motion_callback (_rl_vimvcxt);
}
else if (vi_redoing)
{
_rl_vimvcxt->motion = _rl_vi_last_motion;
r = rl_domove_motion_callback (_rl_vimvcxt);
}
#if defined (READLINE_CALLBACKS)
else if (RL_ISSTATE (RL_STATE_CALLBACK))
{
RL_SETSTATE (RL_STATE_VIMOTION);
return (0);
}
#endif
else
r = rl_vi_domove (key, &c);
if (r < 0)
{
rl_ding ();
return -1;
r = -1; /* normalize return value */
}
_rl_vimvcxt->motion = c;
r = vidomove_dispatch (_rl_vimvcxt);
_rl_mvcxt_dispose (_rl_vimvcxt);
_rl_vimvcxt = 0;
return r;
}
@@ -1266,23 +1363,34 @@ rl_vi_yank_to (count, key)
{
int c, r;
if (_rl_uppercase_p (key))
rl_stuff_char ('$');
_rl_vimvcxt = _rl_mvcxt_alloc (VIM_YANK, key);
_rl_vimvcxt->start = rl_point;
/* XXX -- TODO -- pass and use context in rl_vi_domove */
if (rl_vi_domove (key, &c))
rl_mark = rl_point;
if (_rl_uppercase_p (key))
{
_rl_vimvcxt->motion = '$';
r = rl_domove_motion_callback (_rl_vimvcxt);
}
#if defined (READLINE_CALLBACKS)
else if (RL_ISSTATE (RL_STATE_CALLBACK))
{
RL_SETSTATE (RL_STATE_VIMOTION);
return (0);
}
#endif
else
r = rl_vi_domove (key, &c);
if (r < 0)
{
rl_ding ();
return -1;
r = -1;
}
_rl_vimvcxt->motion = c;
r = vidomove_dispatch (_rl_vimvcxt);
_rl_mvcxt_dispose (_rl_vimvcxt);
_rl_vimvcxt = 0;
return r;
}
@@ -1304,11 +1412,12 @@ vidomove_dispatch (m)
r = vi_yank_dispatch (m);
break;
default:
fprintf (stderr, "vidomove_dispatch: unknown operator %d", m->op);
_rl_errmsg ("vidomove_dispatch: unknown operator %d", m->op);
r = 1;
break;
}
RL_UNSETSTATE (RL_STATE_VIMOTION);
return r;
}
File diff suppressed because it is too large Load Diff
+261 -154
View File
@@ -130,6 +130,10 @@ static int _rl_vi_callback_change_char PARAMS((_rl_callback_generic_arg *));
static int _rl_vi_callback_char_search PARAMS((_rl_callback_generic_arg *));
#endif
static int rl_domove_read_callback PARAMS((_rl_vimotion_cxt *));
static int rl_domove_motion_callback PARAMS((_rl_vimotion_cxt *));
static int rl_vi_domove_getchar PARAMS((_rl_vimotion_cxt *));
static int vi_change_dispatch PARAMS((_rl_vimotion_cxt *));
static int vi_delete_dispatch PARAMS((_rl_vimotion_cxt *));
static int vi_yank_dispatch PARAMS((_rl_vimotion_cxt *));
@@ -918,113 +922,6 @@ rl_vi_column (count, key)
return (0);
}
int
rl_vi_domove (key, nextkey)
int key, *nextkey;
{
int c, save;
int old_end;
rl_mark = rl_point;
RL_SETSTATE(RL_STATE_MOREINPUT);
c = rl_read_key ();
RL_UNSETSTATE(RL_STATE_MOREINPUT);
if (c < 0)
{
*nextkey = 0;
return -1;
}
*nextkey = c;
if (!member (c, vi_motion))
{
if (_rl_digit_p (c))
{
save = rl_numeric_arg;
rl_numeric_arg = _rl_digit_value (c);
rl_explicit_arg = 1;
RL_SETSTATE (RL_STATE_NUMERICARG|RL_STATE_VIMOTION);
rl_digit_loop1 ();
RL_UNSETSTATE (RL_STATE_VIMOTION);
rl_numeric_arg *= save;
RL_SETSTATE(RL_STATE_MOREINPUT);
c = rl_read_key (); /* real command */
RL_UNSETSTATE(RL_STATE_MOREINPUT);
if (c < 0)
{
*nextkey = 0;
return -1;
}
*nextkey = c;
}
else if (key == c && (key == 'd' || key == 'y' || key == 'c'))
{
rl_mark = rl_end;
rl_beg_of_line (1, c);
_rl_vi_last_motion = c;
return (0);
}
else
return (-1);
}
_rl_vi_last_motion = c;
/* Append a blank character temporarily so that the motion routines
work right at the end of the line. */
old_end = rl_end;
rl_line_buffer[rl_end++] = ' ';
rl_line_buffer[rl_end] = '\0';
_rl_dispatch (c, _rl_keymap);
/* Remove the blank that we added. */
rl_end = old_end;
rl_line_buffer[rl_end] = '\0';
if (rl_point > rl_end)
rl_point = rl_end;
/* No change in position means the command failed. */
if (rl_mark == rl_point)
return (-1);
/* rl_vi_f[wW]ord () leaves the cursor on the first character of the next
word. If we are not at the end of the line, and we are on a
non-whitespace character, move back one (presumably to whitespace). */
if ((_rl_to_upper (c) == 'W') && rl_point < rl_end && rl_point > rl_mark &&
!whitespace (rl_line_buffer[rl_point]))
rl_point--;
/* If cw or cW, back up to the end of a word, so the behaviour of ce
or cE is the actual result. Brute-force, no subtlety. */
if (key == 'c' && rl_point >= rl_mark && (_rl_to_upper (c) == 'W'))
{
/* Don't move farther back than where we started. */
while (rl_point > rl_mark && whitespace (rl_line_buffer[rl_point]))
rl_point--;
/* Posix.2 says that if cw or cW moves the cursor towards the end of
the line, the character under the cursor should be deleted. */
if (rl_point == rl_mark)
rl_point++;
else
{
/* Move past the end of the word so that the kill doesn't
remove the last letter of the previous word. Only do this
if we are not at the end of the line. */
if (rl_point >= 0 && rl_point < (rl_end - 1) && !whitespace (rl_line_buffer[rl_point]))
rl_point++;
}
}
if (rl_mark < rl_point)
SWAP (rl_point, rl_mark);
return (0);
}
/* Process C as part of the current numeric argument. Return -1 if the
argument should be aborted, 0 if we should not read any more chars, and
1 if we should continue to read chars. */
@@ -1050,13 +947,13 @@ _rl_vi_arg_dispatch (c)
else
rl_numeric_arg = _rl_digit_value (c);
rl_explicit_arg = 1;
return 1;
return 1; /* keep going */
}
else
{
rl_clear_message ();
rl_stuff_char (key);
return 0;
return 0; /* done */
}
}
@@ -1117,19 +1014,189 @@ _rl_mvcxt_dispose (m)
free (m);
}
/*
* 1. Create context, set initial values
* 2. Pass to rl_vi_domove to populate
* 3. Use returned context to finish rest of command
*
* Context:
* op
* state
* flags
* numeric arg
* start, end positions
* initial key (key), motion key (c)
*/
static int
rl_domove_motion_callback (m)
_rl_vimotion_cxt *m;
{
int c, key, save, r;
int old_end;
_rl_vi_last_motion = c = m->motion;
/* Append a blank character temporarily so that the motion routines
work right at the end of the line. */
old_end = rl_end;
rl_line_buffer[rl_end++] = ' ';
rl_line_buffer[rl_end] = '\0';
_rl_dispatch (c, _rl_keymap);
/* Remove the blank that we added. */
rl_end = old_end;
rl_line_buffer[rl_end] = '\0';
if (rl_point > rl_end)
rl_point = rl_end;
/* No change in position means the command failed. */
if (rl_mark == rl_point)
return (-1);
/* rl_vi_f[wW]ord () leaves the cursor on the first character of the next
word. If we are not at the end of the line, and we are on a
non-whitespace character, move back one (presumably to whitespace). */
if ((_rl_to_upper (c) == 'W') && rl_point < rl_end && rl_point > rl_mark &&
!whitespace (rl_line_buffer[rl_point]))
rl_point--;
/* If cw or cW, back up to the end of a word, so the behaviour of ce
or cE is the actual result. Brute-force, no subtlety. */
if (key == 'c' && rl_point >= rl_mark && (_rl_to_upper (c) == 'W'))
{
/* Don't move farther back than where we started. */
while (rl_point > rl_mark && whitespace (rl_line_buffer[rl_point]))
rl_point--;
/* Posix.2 says that if cw or cW moves the cursor towards the end of
the line, the character under the cursor should be deleted. */
if (rl_point == rl_mark)
rl_point++;
else
{
/* Move past the end of the word so that the kill doesn't
remove the last letter of the previous word. Only do this
if we are not at the end of the line. */
if (rl_point >= 0 && rl_point < (rl_end - 1) && !whitespace (rl_line_buffer[rl_point]))
rl_point++;
}
}
if (rl_mark < rl_point)
SWAP (rl_point, rl_mark);
#if defined (READLINE_CALLBACKS)
if (RL_ISSTATE (RL_STATE_CALLBACK))
(*rl_redisplay_function)(); /* make sure motion is displayed */
#endif
r = vidomove_dispatch (m);
return (r);
}
#define RL_VIMOVENUMARG() (RL_ISSTATE (RL_STATE_VIMOTION) && RL_ISSTATE (RL_STATE_NUMERICARG))
static int
rl_domove_read_callback (m)
_rl_vimotion_cxt *m;
{
int c, save;
c = m->motion;
if (member (c, vi_motion))
{
#if defined (READLINE_CALLBACKS)
/* If we just read a vi-mode motion command numeric argument, turn off
the `reading numeric arg' state */
if (RL_ISSTATE (RL_STATE_CALLBACK) && RL_VIMOVENUMARG())
RL_UNSETSTATE (RL_STATE_NUMERICARG);
#endif
/* Should do everything, including turning off RL_STATE_VIMOTION */
return (rl_domove_motion_callback (m));
}
else if (m->key == c && (m->key == 'd' || m->key == 'y' || m->key == 'c'))
{
rl_mark = rl_end;
rl_beg_of_line (1, c);
_rl_vi_last_motion = c;
RL_UNSETSTATE (RL_STATE_VIMOTION);
return (0);
}
#if defined (READLINE_CALLBACKS)
/* Reading vi motion char continuing numeric argument */
else if (_rl_digit_p (c) && RL_ISSTATE (RL_STATE_CALLBACK) && RL_VIMOVENUMARG())
{
return (_rl_vi_arg_dispatch (c));
}
/* Readine vi motion char starting numeric argument */
else if (_rl_digit_p (c) && RL_ISSTATE (RL_STATE_CALLBACK) && RL_ISSTATE (RL_STATE_VIMOTION) && (RL_ISSTATE (RL_STATE_NUMERICARG) == 0))
{
RL_SETSTATE (RL_STATE_NUMERICARG);
return (_rl_vi_arg_dispatch (c));
}
#endif
else if (_rl_digit_p (c))
{
/* This code path taken when not in callback mode */
save = rl_numeric_arg;
rl_numeric_arg = _rl_digit_value (c);
rl_explicit_arg = 1;
RL_SETSTATE (RL_STATE_NUMERICARG);
rl_digit_loop1 ();
rl_numeric_arg *= save;
c = rl_vi_domove_getchar (m);
if (c < 0)
{
m->motion = 0;
return -1;
}
m->motion = c;
return (rl_domove_motion_callback (m));
}
else
{
RL_UNSETSTATE (RL_STATE_VIMOTION);
return (1);
}
}
static int
rl_vi_domove_getchar (m)
_rl_vimotion_cxt *m;
{
int c;
RL_SETSTATE(RL_STATE_MOREINPUT);
c = rl_read_key ();
RL_UNSETSTATE(RL_STATE_MOREINPUT);
return c;
}
#if defined (READLINE_CALLBACKS)
int
_rl_vi_domove_callback (m)
_rl_vimotion_cxt *m;
{
int c, r;
m->motion = c = rl_vi_domove_getchar (m);
/* XXX - what to do if this returns -1? Should we return 1 for eof to
callback code? */
r = rl_domove_read_callback (m);
return ((r == 0) ? r : 1); /* normalize return values */
}
#endif
/* This code path taken when not in callback mode. */
int
rl_vi_domove (x, ignore)
int x, *ignore;
{
int r;
_rl_vimotion_cxt *m;
*ignore = m->motion = rl_vi_domove_getchar (m = _rl_vimvcxt);
if (m->motion < 0)
{
m->motion = 0;
return -1;
}
return (rl_domove_read_callback (m));
}
static int
vi_delete_dispatch (m)
@@ -1151,25 +1218,39 @@ rl_vi_delete_to (count, key)
{
int c, r;
if (_rl_uppercase_p (key))
rl_stuff_char ('$');
else if (vi_redoing)
rl_stuff_char (_rl_vi_last_motion);
_rl_vimvcxt = _rl_mvcxt_alloc (VIM_DELETE, key);
_rl_vimvcxt->start = rl_point;
/* XXX -- TODO -- pass and use context in rl_vi_domove */
if (rl_vi_domove (key, &c))
rl_mark = rl_point;
if (_rl_uppercase_p (key))
{
_rl_vimvcxt->motion = '$';
r = rl_domove_motion_callback (_rl_vimvcxt);
}
else if (vi_redoing)
{
_rl_vimvcxt->motion = _rl_vi_last_motion;
r = rl_domove_motion_callback (_rl_vimvcxt);
}
#if defined (READLINE_CALLBACKS)
else if (RL_ISSTATE (RL_STATE_CALLBACK))
{
RL_SETSTATE (RL_STATE_VIMOTION);
return (0);
}
#endif
else
r = rl_vi_domove (key, &c);
if (r < 0)
{
rl_ding ();
return -1;
r = -1;
}
_rl_vimvcxt->motion = c;
r = vidomove_dispatch (_rl_vimvcxt);
_rl_mvcxt_dispose (_rl_vimvcxt);
_rl_vimvcxt = 0;
return r;
}
@@ -1219,25 +1300,39 @@ rl_vi_change_to (count, key)
{
int c, r;
if (_rl_uppercase_p (key))
rl_stuff_char ('$');
else if (vi_redoing)
rl_stuff_char (_rl_vi_last_motion);
_rl_vimvcxt = _rl_mvcxt_alloc (VIM_CHANGE, key);
_rl_vimvcxt->start = rl_point;
/* XXX -- TODO -- pass and use context in rl_vi_domove */
if (rl_vi_domove (key, &c))
rl_mark = rl_point;
if (_rl_uppercase_p (key))
{
_rl_vimvcxt->motion = '$';
r = rl_domove_motion_callback (_rl_vimvcxt);
}
else if (vi_redoing)
{
_rl_vimvcxt->motion = _rl_vi_last_motion;
r = rl_domove_motion_callback (_rl_vimvcxt);
}
#if defined (READLINE_CALLBACKS)
else if (RL_ISSTATE (RL_STATE_CALLBACK))
{
RL_SETSTATE (RL_STATE_VIMOTION);
return (0);
}
#endif
else
r = rl_vi_domove (key, &c);
if (r < 0)
{
rl_ding ();
return -1;
r = -1; /* normalize return value */
}
_rl_vimvcxt->motion = c;
r = vidomove_dispatch (_rl_vimvcxt);
_rl_mvcxt_dispose (_rl_vimvcxt);
_rl_vimvcxt = 0;
return r;
}
@@ -1266,23 +1361,34 @@ rl_vi_yank_to (count, key)
{
int c, r;
if (_rl_uppercase_p (key))
rl_stuff_char ('$');
_rl_vimvcxt = _rl_mvcxt_alloc (VIM_YANK, key);
_rl_vimvcxt->start = rl_point;
/* XXX -- TODO -- pass and use context in rl_vi_domove */
if (rl_vi_domove (key, &c))
rl_mark = rl_point;
if (_rl_uppercase_p (key))
{
_rl_vimvcxt->motion = '$';
r = rl_domove_motion_callback (_rl_vimvcxt);
}
#if defined (READLINE_CALLBACKS)
else if (RL_ISSTATE (RL_STATE_CALLBACK))
{
RL_SETSTATE (RL_STATE_VIMOTION);
return (0);
}
#endif
else
r = rl_vi_domove (key, &c);
if (r < 0)
{
rl_ding ();
return -1;
r = -1;
}
_rl_vimvcxt->motion = c;
r = vidomove_dispatch (_rl_vimvcxt);
_rl_mvcxt_dispose (_rl_vimvcxt);
_rl_vimvcxt = 0;
return r;
}
@@ -1295,20 +1401,21 @@ vidomove_dispatch (m)
switch (m->op)
{
case VIM_DELETE:
r = vi_delete_callback (m);
r = vi_delete_dispatch (m);
break;
case VIM_CHANGE:
r = vi_change_callback (m);
r = vi_change_dispatch (m);
break;
case VIM_YANK:
r = vi_yank_callback (m);
r = vi_yank_dispatch (m);
break;
default:
fprintf (stderr, "vidomove_dispatch: unknown operator %d", m->op);
_rl_errmsg ("vidomove_dispatch: unknown operator %d", m->op);
r = 1;
break;
}
RL_UNSETSTATE (RL_STATE_VIMOTION);
return r;
}
+6 -1
View File
@@ -92,7 +92,7 @@ CSOURCES = clktck.c clock.c getcwd.c getenv.c oslib.c setlinebuf.c \
mktime.c strftime.c mbschr.c zcatfd.c zmapfd.c winsize.c eaccess.c \
wcsdup.c fpurge.c zgetline.c mbscmp.c uconvert.c ufuncs.c \
casemod.c dprintf.c input_avail.c mbscasecmp.c fnxform.c \
strchrnul.c unicode.c
strchrnul.c unicode.c wcswidth.c
# The header files for this library.
HSOURCES =
@@ -196,6 +196,7 @@ uconvert.o: uconvert.c
ufuncs.o: ufuncs.c
vprint.o: vprint.c
wcsdup.o: wcsdup.c
wcswidth.o: wcswidth.c
mbschr.o: mbschr.c
zcatfd.o: zcatfd.c
zmapfd.o: zmapfd.c
@@ -266,6 +267,7 @@ uconvert.o: ${BUILD_DIR}/config.h
ufuncs.o: ${BUILD_DIR}/config.h
vprint.o: ${BUILD_DIR}/config.h
wcsdup.o: ${BUILD_DIR}/config.h
wcswidth.o: ${BUILD_DIR}/config.h
mbschr.o: ${BUILD_DIR}/config.h
zcatfd.o: ${BUILD_DIR}/config.h
zgetline.o: ${BUILD_DIR}/config.h
@@ -506,6 +508,9 @@ wcsdup.o: ${topdir}/bashansi.h ${BASHINCDIR}/ansi_stdlib.h
wcsdup.o: ${BASHINCDIR}/stdc.h
wcsdup.o: ${topdir}/xmalloc.h
wcswidth.o: ${topdir}/bashansi.h ${BASHINCDIR}/ansi_stdlib.h
wcswidth.o: ${BASHINCDIR}/stdc.h
mbschr.o: ${topdir}/bashansi.h
mbschr.o: ${BASHINCDIR}/ansi_stdlib.h
mbschr.o: ${BASHINCDIR}/shmbutil.h
+3 -3
View File
@@ -2,7 +2,7 @@
# Makefile for the Bash library
#
#
# Copyright (C) 1998-2009 Free Software Foundation, Inc.
# Copyright (C) 1998-2010 Free Software Foundation, Inc.
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -92,7 +92,7 @@ CSOURCES = clktck.c clock.c getcwd.c getenv.c oslib.c setlinebuf.c \
mktime.c strftime.c mbschr.c zcatfd.c zmapfd.c winsize.c eaccess.c \
wcsdup.c fpurge.c zgetline.c mbscmp.c uconvert.c ufuncs.c \
casemod.c dprintf.c input_avail.c mbscasecmp.c fnxform.c \
strchrnul.c
strchrnul.c unicode.c
# The header files for this library.
HSOURCES =
@@ -106,7 +106,7 @@ OBJECTS = clktck.o clock.o getenv.o oslib.o setlinebuf.o strnlen.o \
strtrans.o snprintf.o mailstat.o fmtulong.o \
fmtullong.o fmtumax.o zcatfd.o zmapfd.o winsize.o wcsdup.o \
fpurge.o zgetline.o mbscmp.o uconvert.o ufuncs.o casemod.o \
input_avail.o mbscasecmp.o fnxform.o ${LIBOBJS}
input_avail.o mbscasecmp.o fnxform.o unicode.o ${LIBOBJS}
SUPPORT = Makefile
+46
View File
@@ -0,0 +1,46 @@
/* wcswidth.c - compute display width of wide character string */
/* Copyright (C) 2010 Free Software Foundation, Inc.
This file is part of GNU Bash, the Bourne Again SHell.
Bash is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Bash is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Bash. If not, see <http://www.gnu.org/licenses/>.
*/
#include <config.h>
#if defined (HANDLE_MULTIBYTE) && !defined (HAVE_WCSWIDTH)
#include <stdc.h>
#include <wchar.h>
#include <bashansi.h>
int
wcswidth(pwcs, n)
const wchar_t *pwcs;
size_t n;
{
wchar_t wc;
int len, l;
len = 0;
while (n-- > 0 && (wc = *pwcs++) != L'\0')
{
if ((l = wcwidth(wc)) < 0)
return (-1);
len += l;
}
return (len);
}
#endif
+26
View File
@@ -0,0 +1,26 @@
#include <config.h>
#if defined (HANDLE_MULTIBYTE) && !defined (HAVE_WCSWIDTH)
#include <stdc.h>
#include <wchar.h>
#include <bashansi.h>
int
wcswidth(pwcs, n)
const wchar_t *pwcs;
size_t n;
{
wchar_t wc;
int len, l;
len = 0;
while (n-- > 0 && (wc = *pwcs++) != L'\0')
{
if ((l = wcwidth(wc)) < 0)
return (-1);
len += l;
}
return (len);
}
+1 -1
View File
@@ -1,2 +1,2 @@
# Set of available languages.
en@quot en@boldquot af bg ca cs de eo es et fi fr ga hu id ja lt nl pl pt_BR ro ru sk sv tr vi zh_CN zh_TW
en@quot en@boldquot af bg ca cs de eo es et fi fr ga hu id ja lt nl pl pt_BR ro ru sk sv tr uk vi zh_CN zh_TW
+5247
View File
File diff suppressed because it is too large Load Diff
+1 -3
View File
@@ -603,9 +603,7 @@ unary_test (op, arg)
case 'v':
v = find_variable (arg);
if (v == 0)
return (FALSE);
return (var_isset (v) ? TRUE : FALSE);
return (v && var_isset (v) ? TRUE : FALSE);
}
/* We can't actually get here, but this shuts up gcc. */
+1 -1
View File
@@ -2,7 +2,7 @@
/* Modified to run with the GNU shell Apr 25, 1988 by bfox. */
/* Copyright (C) 1987-2009 Free Software Foundation, Inc.
/* Copyright (C) 1987-2010 Free Software Foundation, Inc.
This file is part of GNU Bash, the Bourne Again SHell.
+1 -1
View File
@@ -1,4 +1,4 @@
BUILD_DIR=/usr/local/build/bash/bash-current
BUILD_DIR=/usr/local/build/chet/bash/bash-current
THIS_SH=$BUILD_DIR/bash
PATH=$PATH:$BUILD_DIR