Hi, When doing 'info bash' and Enter, followed by '/shopt' and twice Enter, one ends up in the middle of the description of 'declare', instead of at the top of the page. Apparently texinfo contains a bug: when a node contains a reference to itself, any reference jumps to that reference instead of to the top of the node.
Anyway, the Bash Builtin Commands node is so big, it seems more useful to make each reference to one of its commands go directly to that command instead of dropping the user at the top of the node. Attached patch does this for the 'shopt' command. In doing so it removes the self reference of the node, so that other references to Bash Builtins now go to the top of the page. If this seems like a good idea, I can make anchors for the other references to this node too. Benno
diff -ur bash-3.2.orig/doc/bashref.texi bash-3.2.new/doc/bashref.texi --- bash-3.2.orig/doc/bashref.texi 2006-09-28 16:25:28.000000000 +0200 +++ bash-3.2.new/doc/bashref.texi 2006-12-03 14:08:17.000000000 +0100 @@ -562,7 +562,7 @@ In a non-interactive shell, or an interactive shell in which the @code{interactive_comments} option to the @code{shopt} -builtin is enabled (@pxref{Bash Builtins}), +builtin is enabled (@pxref{Bash Builtin shopt}), a word beginning with @samp{#} causes that word and all remaining characters on that line to be ignored. An interactive shell without the @code{interactive_comments} @@ -848,7 +848,7 @@ @code{case} will selectively execute the @var{command-list} corresponding to the first @var{pattern} that matches @var{word}. If the shell option @code{nocasematch} -(see the description of @code{shopt} in @ref{Bash Builtins}) +(@pxref{Bash Builtin shopt}) is enabled, the match is performed without regard to the case of alphabetic characters. The @samp{|} is used to separate multiple patterns, and the @samp{)} @@ -960,7 +960,7 @@ right of the operator is considered a pattern and matched according to the rules described below in @ref{Pattern Matching}. If the shell option @code{nocasematch} -(see the description of @code{shopt} in @ref{Bash Builtins}) +(@pxref{Bash Builtin shopt}) is enabled, the match is performed without regard to the case of alphabetic characters. The return value is 0 if the string matches (@samp{==}) or does not @@ -977,7 +977,7 @@ If the regular expression is syntactically incorrect, the conditional expression's return value is 2. If the shell option @code{nocasematch} -(see the description of @code{shopt} in @ref{Bash Builtins}) +(@pxref{Bash Builtin shopt}) is enabled, the match is performed without regard to the case of alphabetic characters. Substrings matched by parenthesized subexpressions within the regular @@ -1840,7 +1840,7 @@ matched explicitly. In other cases, the @samp{.} character is not treated specially. -See the description of @code{shopt} in @ref{Bash Builtins}, [EMAIL PROTECTED] Builtin shopt}, for a description of the @code{nocaseglob}, @code{nullglob}, @code{failglob}, and @code{dotglob} options. @@ -2508,7 +2508,7 @@ to not receive @code{SIGHUP} using @code{disown -h}. If the @code{huponexit} shell option has been set with @code{shopt} -(@pxref{Bash Builtins}), Bash sends a @code{SIGHUP} to all jobs when +(@pxref{Bash Builtin shopt}), Bash sends a @code{SIGHUP} to all jobs when an interactive login shell exits. If Bash is waiting for a command to complete and receives a signal @@ -3014,7 +3014,7 @@ @code{select} command, every arithmetic @code{for} command, and before the first command executes in a shell function. Refer to the description of the @code{extglob} option to the [EMAIL PROTECTED] builtin (@pxref{Bash Builtins}) for details of its [EMAIL PROTECTED] builtin (@pxref{Bash Builtin shopt}) for details of its effect on the @code{DEBUG} trap. If a @var{sigspec} is @code{ERR}, the command @var{arg} is executed whenever a simple command has a non-zero exit status, @@ -3250,7 +3251,7 @@ The @option{-F} option inhibits the display of function definitions; only the function name and attributes are printed. If the @code{extdebug} shell option is enabled using @code{shopt} -(@pxref{Bash Builtins}), the source file name and line number where +(@pxref{Bash Builtin shopt}), the source file name and line number where the function is defined are displayed as well. @option{-F} implies @option{-f}. The following options can be used to restrict output to variables with @@ -3521,6 +3522,7 @@ @end table [EMAIL PROTECTED] Builtin shopt} @item shopt @btindex shopt @example @@ -4310,7 +4312,7 @@ subroutine is executed, the number of parameters passed is pushed onto @code{BASH_ARGC}. The shell sets @code{BASH_ARGC} only when in extended debugging mode -(see @ref{Bash Builtins} +(see @ref{Bash Builtin shopt} for a description of the @code{extdebug} option to the @code{shopt} builtin). @@ -4321,7 +4323,7 @@ at the bottom. When a subroutine is executed, the parameters supplied are pushed onto @code{BASH_ARGV}. The shell sets @code{BASH_ARGV} only when in extended debugging mode -(see @ref{Bash Builtins} +(see @ref{Bash Builtin shopt} for a description of the @code{extdebug} option to the @code{shopt} builtin). @@ -4850,7 +4852,7 @@ @table @code @item --debugger Arrange for the debugger profile to be executed before the shell -starts. Turns on extended debugging mode (see @ref{Bash Builtins} +starts. Turns on extended debugging mode (see @ref{Bash Builtin shopt} for a description of the @code{extdebug} option to the @code{shopt} builtin) and shell function tracing (see @ref{The Set Builtin} for a description of the @code{-o functrace} @@ -4953,7 +4955,7 @@ @item [-+]O [EMAIL PROTECTED] @var{shopt_option} is one of the shell options accepted by the [EMAIL PROTECTED] builtin (@pxref{Shell Builtin Commands}). [EMAIL PROTECTED] builtin (@pxref{Bash Builtin shopt}). If @var{shopt_option} is present, @option{-O} sets the value of that option; @option{+O} unsets it. If @var{shopt_option} is not supplied, the names and values of the shell @@ -5252,7 +5254,7 @@ @item Simple spelling correction for directory arguments to the @code{cd} builtin is enabled by default (see the description of the @code{cdspell} -option to the @code{shopt} builtin in @ref{Bash Builtins}). +option to the @code{shopt} builtin in @ref{Bash Builtin shopt}). @item The shell will check the value of the @env{TMOUT} variable and exit @@ -5536,7 +5538,7 @@ Aliases are not expanded when the shell is not interactive, unless the @code{expand_aliases} shell option is set using [EMAIL PROTECTED] (@pxref{Bash Builtins}). [EMAIL PROTECTED] (@pxref{Bash Builtin shopt}). The rules concerning the definition and use of aliases are somewhat confusing. Bash @@ -7225,7 +7227,7 @@ @item Bash includes the @code{shopt} builtin, for finer control of shell -optional capabilities (@pxref{Bash Builtins}), and allows these options +optional capabilities (@pxref{Bash Builtin shopt}), and allows these options to be set and unset at shell invocation (@pxref{Invoking Bash}). @item
_______________________________________________ Bug-bash mailing list Bug-bash@gnu.org http://lists.gnu.org/mailman/listinfo/bug-bash