mirror of
https://https.git.savannah.gnu.org/git/bash.git
synced 2026-08-09 11:40:30 +02:00
bash asan fixes; minor documentation updates
This commit is contained in:
+177
-168
@@ -2,9 +2,9 @@ This is bashref.info, produced by makeinfo version 6.8 from
|
||||
bashref.texi.
|
||||
|
||||
This text is a brief description of the features that are present in the
|
||||
Bash shell (version 5.2, 20 February 2023).
|
||||
Bash shell (version 5.2, 14 March 2023).
|
||||
|
||||
This is Edition 5.2, last updated 20 February 2023, of 'The GNU Bash
|
||||
This is Edition 5.2, last updated 14 March 2023, of 'The GNU Bash
|
||||
Reference Manual', for 'Bash', Version 5.2.
|
||||
|
||||
Copyright (C) 1988-2023 Free Software Foundation, Inc.
|
||||
@@ -27,10 +27,10 @@ Bash Features
|
||||
*************
|
||||
|
||||
This text is a brief description of the features that are present in the
|
||||
Bash shell (version 5.2, 20 February 2023). The Bash home page is
|
||||
Bash shell (version 5.2, 14 March 2023). The Bash home page is
|
||||
<http://www.gnu.org/software/bash/>.
|
||||
|
||||
This is Edition 5.2, last updated 20 February 2023, of 'The GNU Bash
|
||||
This is Edition 5.2, last updated 14 March 2023, of 'The GNU Bash
|
||||
Reference Manual', for 'Bash', Version 5.2.
|
||||
|
||||
Bash contains features that appear in other popular shells, and some
|
||||
@@ -2327,19 +2327,23 @@ quotes for word splitting.
|
||||
|
||||
The shell treats each character of '$IFS' as a delimiter, and splits
|
||||
the results of the other expansions into words using these characters as
|
||||
field terminators. If 'IFS' is unset, or its value is exactly
|
||||
'<space><tab><newline>', the default, then sequences of ' <space>',
|
||||
'<tab>', and '<newline>' at the beginning and end of the results of the
|
||||
previous expansions are ignored, and any sequence of 'IFS' characters
|
||||
not at the beginning or end serves to delimit words. If 'IFS' has a
|
||||
value other than the default, then sequences of the whitespace
|
||||
characters 'space', 'tab', and 'newline' are ignored at the beginning
|
||||
and end of the word, as long as the whitespace character is in the value
|
||||
of 'IFS' (an 'IFS' whitespace character). Any character in 'IFS' that
|
||||
is not 'IFS' whitespace, along with any adjacent 'IFS' whitespace
|
||||
characters, delimits a field. A sequence of 'IFS' whitespace characters
|
||||
is also treated as a delimiter. If the value of 'IFS' is null, no word
|
||||
splitting occurs.
|
||||
field terminators.
|
||||
|
||||
If 'IFS' is unset, or its value is exactly '<space><tab><newline>',
|
||||
the default, then sequences of 'space', 'tab', and 'newline' at the
|
||||
beginning and end of the results of the previous expansions are ignored,
|
||||
and any sequence of 'IFS' characters not at the beginning or end serves
|
||||
to delimit words. If 'IFS' has a value other than the default, then
|
||||
sequences of the whitespace characters 'space', 'tab', and 'newline' are
|
||||
ignored at the beginning and end of the word, as long as the whitespace
|
||||
character is in the value of 'IFS' (an 'IFS' whitespace character). Any
|
||||
character in 'IFS' that is not 'IFS' whitespace, along with any adjacent
|
||||
'IFS' whitespace characters, delimits a field. A sequence of 'IFS'
|
||||
whitespace characters is also treated as a delimiter.
|
||||
|
||||
If the value of 'IFS' is null, no word splitting occurs. If 'IFS' is
|
||||
unset, word splitting behaves as if it contained the default value
|
||||
'<space><tab><newline>'.
|
||||
|
||||
Explicit null arguments ('""' or '''') are retained and passed to
|
||||
commands as empty strings. Unquoted implicit null arguments, resulting
|
||||
@@ -2679,7 +2683,7 @@ This is semantically equivalent to
|
||||
--------------------
|
||||
|
||||
This type of redirection instructs the shell to read input from the
|
||||
current source until a line containing only WORD (with no trailing
|
||||
current source until a line containing only DELIMITER (with no trailing
|
||||
blanks) is seen. All of the lines read up to that point are then used
|
||||
as the standard input (or file descriptor N if N is specified) for a
|
||||
command.
|
||||
@@ -2690,13 +2694,15 @@ command.
|
||||
DELIMITER
|
||||
|
||||
No parameter and variable expansion, command substitution, arithmetic
|
||||
expansion, or filename expansion is performed on WORD. If any part of
|
||||
WORD is quoted, the DELIMITER is the result of quote removal on WORD,
|
||||
and the lines in the here-document are not expanded. If WORD is
|
||||
unquoted, all lines of the here-document are subjected to parameter
|
||||
expansion, command substitution, and arithmetic expansion, the character
|
||||
sequence '\newline' is ignored, and '\' must be used to quote the
|
||||
characters '\', '$', and '`'.
|
||||
expansion, or filename expansion is performed on WORD.
|
||||
|
||||
If any part of WORD is quoted, the DELIMITER is the result of quote
|
||||
removal on WORD, and the lines in the here-document are not expanded.
|
||||
If WORD is unquoted, DELIMITER is WORD itself, all lines of the
|
||||
here-document are subjected to parameter expansion, command
|
||||
substitution, and arithmetic expansion, the character sequence
|
||||
'\newline' is ignored, and '\' must be used to quote the characters '\',
|
||||
'$', and '`'.
|
||||
|
||||
If the redirection operator is '<<-', then all leading tab characters
|
||||
are stripped from input lines and the line containing DELIMITER. This
|
||||
@@ -6703,8 +6709,10 @@ indexed arrays, if the optional subscript is supplied, that index is
|
||||
assigned to; otherwise the index of the element assigned is the last
|
||||
index assigned to by the statement plus one. Indexing starts at zero.
|
||||
|
||||
Each VALUE in the list undergoes all the shell expansions described
|
||||
above (*note Shell Expansions::).
|
||||
Each VALUE in the list undergoes the shell expansions described above
|
||||
(*note Shell Expansions::), but VALUEs that are valid variable
|
||||
assignments including the brackets and subscript do not undergo brace
|
||||
expansion and word splitting, as with individual variable assignments.
|
||||
|
||||
When assigning to an associative array, the words in a compound
|
||||
assignment may be either assignment statements, for which the subscript
|
||||
@@ -9412,9 +9420,10 @@ File: bashref.info, Node: Miscellaneous Commands, Prev: Keyboard Macros, Up:
|
||||
Display version information about the current instance of Bash.
|
||||
|
||||
'shell-expand-line (M-C-e)'
|
||||
Expand the line as the shell does. This performs alias and history
|
||||
expansion as well as all of the shell word expansions (*note Shell
|
||||
Expansions::).
|
||||
Expand the line by performing shell word expansions. This performs
|
||||
alias and history expansion, $'STRING' and $"STRING" quoting, tilde
|
||||
expansion, parameter and variable expansion, arithmetic expansion,
|
||||
word splitting, and quote removal.
|
||||
|
||||
'history-expand-line (M-^)'
|
||||
Perform history expansion on the current line.
|
||||
@@ -12241,7 +12250,7 @@ D.4 Function Index
|
||||
* accept-line (Newline or Return): Commands For History.
|
||||
(line 6)
|
||||
* alias-expand-line (): Miscellaneous Commands.
|
||||
(line 131)
|
||||
(line 132)
|
||||
* backward-char (C-b): Commands For Moving. (line 15)
|
||||
* backward-delete-char (Rubout): Commands For Text. (line 17)
|
||||
* backward-kill-line (C-x Rubout): Commands For Killing.
|
||||
@@ -12303,7 +12312,7 @@ D.4 Function Index
|
||||
* dynamic-complete-history (M-<TAB>): Commands For Completion.
|
||||
(line 90)
|
||||
* edit-and-execute-command (C-x C-e): Miscellaneous Commands.
|
||||
(line 140)
|
||||
(line 141)
|
||||
* end-kbd-macro (C-x )): Keyboard Macros. (line 9)
|
||||
* end-of-file (usually C-d): Commands For Text. (line 6)
|
||||
* end-of-history (M->): Commands For History.
|
||||
@@ -12325,9 +12334,9 @@ D.4 Function Index
|
||||
* glob-list-expansions (C-x g): Miscellaneous Commands.
|
||||
(line 110)
|
||||
* history-and-alias-expand-line (): Miscellaneous Commands.
|
||||
(line 134)
|
||||
(line 135)
|
||||
* history-expand-line (M-^): Miscellaneous Commands.
|
||||
(line 124)
|
||||
(line 125)
|
||||
* history-search-backward (): Commands For History.
|
||||
(line 57)
|
||||
* history-search-forward (): Commands For History.
|
||||
@@ -12341,7 +12350,7 @@ D.4 Function Index
|
||||
* insert-completions (M-*): Commands For Completion.
|
||||
(line 22)
|
||||
* insert-last-argument (M-. or M-_): Miscellaneous Commands.
|
||||
(line 137)
|
||||
(line 138)
|
||||
* kill-line (C-k): Commands For Killing.
|
||||
(line 6)
|
||||
* kill-region (): Commands For Killing.
|
||||
@@ -12351,7 +12360,7 @@ D.4 Function Index
|
||||
* kill-word (M-d): Commands For Killing.
|
||||
(line 23)
|
||||
* magic-space (): Miscellaneous Commands.
|
||||
(line 127)
|
||||
(line 128)
|
||||
* menu-complete (): Commands For Completion.
|
||||
(line 26)
|
||||
* menu-complete-backward (): Commands For Completion.
|
||||
@@ -12604,138 +12613,138 @@ D.5 Concept Index
|
||||
|
||||
|
||||
Tag Table:
|
||||
Node: Top897
|
||||
Node: Introduction2817
|
||||
Node: What is Bash?3033
|
||||
Node: What is a shell?4147
|
||||
Node: Definitions6685
|
||||
Node: Basic Shell Features9636
|
||||
Node: Shell Syntax10855
|
||||
Node: Shell Operation11881
|
||||
Node: Quoting13174
|
||||
Node: Escape Character14478
|
||||
Node: Single Quotes14963
|
||||
Node: Double Quotes15311
|
||||
Node: ANSI-C Quoting16589
|
||||
Node: Locale Translation17899
|
||||
Node: Creating Internationalized Scripts19210
|
||||
Node: Comments23327
|
||||
Node: Shell Commands23945
|
||||
Node: Reserved Words24883
|
||||
Node: Simple Commands25639
|
||||
Node: Pipelines26293
|
||||
Node: Lists29292
|
||||
Node: Compound Commands31087
|
||||
Node: Looping Constructs32099
|
||||
Node: Conditional Constructs34594
|
||||
Node: Command Grouping49082
|
||||
Node: Coprocesses50560
|
||||
Node: GNU Parallel53223
|
||||
Node: Shell Functions54140
|
||||
Node: Shell Parameters62025
|
||||
Node: Positional Parameters66413
|
||||
Node: Special Parameters67315
|
||||
Node: Shell Expansions70529
|
||||
Node: Brace Expansion72656
|
||||
Node: Tilde Expansion75390
|
||||
Node: Shell Parameter Expansion78011
|
||||
Node: Command Substitution96413
|
||||
Node: Arithmetic Expansion97768
|
||||
Node: Process Substitution98736
|
||||
Node: Word Splitting99856
|
||||
Node: Filename Expansion101800
|
||||
Node: Pattern Matching104549
|
||||
Node: Quote Removal109551
|
||||
Node: Redirections109846
|
||||
Node: Executing Commands119506
|
||||
Node: Simple Command Expansion120176
|
||||
Node: Command Search and Execution122286
|
||||
Node: Command Execution Environment124673
|
||||
Node: Environment127708
|
||||
Node: Exit Status129371
|
||||
Node: Signals131155
|
||||
Node: Shell Scripts134604
|
||||
Node: Shell Builtin Commands137631
|
||||
Node: Bourne Shell Builtins139669
|
||||
Node: Bash Builtins161867
|
||||
Node: Modifying Shell Behavior193866
|
||||
Node: The Set Builtin194211
|
||||
Node: The Shopt Builtin204809
|
||||
Node: Special Builtins220721
|
||||
Node: Shell Variables221700
|
||||
Node: Bourne Shell Variables222137
|
||||
Node: Bash Variables224241
|
||||
Node: Bash Features257056
|
||||
Node: Invoking Bash258069
|
||||
Node: Bash Startup Files264082
|
||||
Node: Interactive Shells269213
|
||||
Node: What is an Interactive Shell?269624
|
||||
Node: Is this Shell Interactive?270273
|
||||
Node: Interactive Shell Behavior271088
|
||||
Node: Bash Conditional Expressions274717
|
||||
Node: Shell Arithmetic279359
|
||||
Node: Aliases282303
|
||||
Node: Arrays285197
|
||||
Node: The Directory Stack291588
|
||||
Node: Directory Stack Builtins292372
|
||||
Node: Controlling the Prompt296632
|
||||
Node: The Restricted Shell299597
|
||||
Node: Bash POSIX Mode302207
|
||||
Node: Shell Compatibility Mode315073
|
||||
Node: Job Control323640
|
||||
Node: Job Control Basics324100
|
||||
Node: Job Control Builtins329102
|
||||
Node: Job Control Variables334897
|
||||
Node: Command Line Editing336053
|
||||
Node: Introduction and Notation337724
|
||||
Node: Readline Interaction339347
|
||||
Node: Readline Bare Essentials340538
|
||||
Node: Readline Movement Commands342327
|
||||
Node: Readline Killing Commands343287
|
||||
Node: Readline Arguments345208
|
||||
Node: Searching346252
|
||||
Node: Readline Init File348438
|
||||
Node: Readline Init File Syntax349699
|
||||
Node: Conditional Init Constructs373490
|
||||
Node: Sample Init File377686
|
||||
Node: Bindable Readline Commands380810
|
||||
Node: Commands For Moving382014
|
||||
Node: Commands For History384065
|
||||
Node: Commands For Text389059
|
||||
Node: Commands For Killing392708
|
||||
Node: Numeric Arguments395741
|
||||
Node: Commands For Completion396880
|
||||
Node: Keyboard Macros401071
|
||||
Node: Miscellaneous Commands401759
|
||||
Node: Readline vi Mode407704
|
||||
Node: Programmable Completion408611
|
||||
Node: Programmable Completion Builtins416391
|
||||
Node: A Programmable Completion Example427143
|
||||
Node: Using History Interactively432391
|
||||
Node: Bash History Facilities433075
|
||||
Node: Bash History Builtins436080
|
||||
Node: History Interaction441104
|
||||
Node: Event Designators444724
|
||||
Node: Word Designators446078
|
||||
Node: Modifiers447838
|
||||
Node: Installing Bash449646
|
||||
Node: Basic Installation450783
|
||||
Node: Compilers and Options454505
|
||||
Node: Compiling For Multiple Architectures455246
|
||||
Node: Installation Names456938
|
||||
Node: Specifying the System Type459047
|
||||
Node: Sharing Defaults459764
|
||||
Node: Operation Controls460437
|
||||
Node: Optional Features461395
|
||||
Node: Reporting Bugs472614
|
||||
Node: Major Differences From The Bourne Shell473958
|
||||
Node: GNU Free Documentation License490807
|
||||
Node: Indexes515984
|
||||
Node: Builtin Index516438
|
||||
Node: Reserved Word Index523265
|
||||
Node: Variable Index525713
|
||||
Node: Function Index542628
|
||||
Node: Concept Index556412
|
||||
Node: Top891
|
||||
Node: Introduction2805
|
||||
Node: What is Bash?3021
|
||||
Node: What is a shell?4135
|
||||
Node: Definitions6673
|
||||
Node: Basic Shell Features9624
|
||||
Node: Shell Syntax10843
|
||||
Node: Shell Operation11869
|
||||
Node: Quoting13162
|
||||
Node: Escape Character14466
|
||||
Node: Single Quotes14951
|
||||
Node: Double Quotes15299
|
||||
Node: ANSI-C Quoting16577
|
||||
Node: Locale Translation17887
|
||||
Node: Creating Internationalized Scripts19198
|
||||
Node: Comments23315
|
||||
Node: Shell Commands23933
|
||||
Node: Reserved Words24871
|
||||
Node: Simple Commands25627
|
||||
Node: Pipelines26281
|
||||
Node: Lists29280
|
||||
Node: Compound Commands31075
|
||||
Node: Looping Constructs32087
|
||||
Node: Conditional Constructs34582
|
||||
Node: Command Grouping49070
|
||||
Node: Coprocesses50548
|
||||
Node: GNU Parallel53211
|
||||
Node: Shell Functions54128
|
||||
Node: Shell Parameters62013
|
||||
Node: Positional Parameters66401
|
||||
Node: Special Parameters67303
|
||||
Node: Shell Expansions70517
|
||||
Node: Brace Expansion72644
|
||||
Node: Tilde Expansion75378
|
||||
Node: Shell Parameter Expansion77999
|
||||
Node: Command Substitution96401
|
||||
Node: Arithmetic Expansion97756
|
||||
Node: Process Substitution98724
|
||||
Node: Word Splitting99844
|
||||
Node: Filename Expansion101892
|
||||
Node: Pattern Matching104641
|
||||
Node: Quote Removal109643
|
||||
Node: Redirections109938
|
||||
Node: Executing Commands119631
|
||||
Node: Simple Command Expansion120301
|
||||
Node: Command Search and Execution122411
|
||||
Node: Command Execution Environment124798
|
||||
Node: Environment127833
|
||||
Node: Exit Status129496
|
||||
Node: Signals131280
|
||||
Node: Shell Scripts134729
|
||||
Node: Shell Builtin Commands137756
|
||||
Node: Bourne Shell Builtins139794
|
||||
Node: Bash Builtins161992
|
||||
Node: Modifying Shell Behavior193991
|
||||
Node: The Set Builtin194336
|
||||
Node: The Shopt Builtin204934
|
||||
Node: Special Builtins220846
|
||||
Node: Shell Variables221825
|
||||
Node: Bourne Shell Variables222262
|
||||
Node: Bash Variables224366
|
||||
Node: Bash Features257181
|
||||
Node: Invoking Bash258194
|
||||
Node: Bash Startup Files264207
|
||||
Node: Interactive Shells269338
|
||||
Node: What is an Interactive Shell?269749
|
||||
Node: Is this Shell Interactive?270398
|
||||
Node: Interactive Shell Behavior271213
|
||||
Node: Bash Conditional Expressions274842
|
||||
Node: Shell Arithmetic279484
|
||||
Node: Aliases282428
|
||||
Node: Arrays285322
|
||||
Node: The Directory Stack291885
|
||||
Node: Directory Stack Builtins292669
|
||||
Node: Controlling the Prompt296929
|
||||
Node: The Restricted Shell299894
|
||||
Node: Bash POSIX Mode302504
|
||||
Node: Shell Compatibility Mode315370
|
||||
Node: Job Control323937
|
||||
Node: Job Control Basics324397
|
||||
Node: Job Control Builtins329399
|
||||
Node: Job Control Variables335194
|
||||
Node: Command Line Editing336350
|
||||
Node: Introduction and Notation338021
|
||||
Node: Readline Interaction339644
|
||||
Node: Readline Bare Essentials340835
|
||||
Node: Readline Movement Commands342624
|
||||
Node: Readline Killing Commands343584
|
||||
Node: Readline Arguments345505
|
||||
Node: Searching346549
|
||||
Node: Readline Init File348735
|
||||
Node: Readline Init File Syntax349996
|
||||
Node: Conditional Init Constructs373787
|
||||
Node: Sample Init File377983
|
||||
Node: Bindable Readline Commands381107
|
||||
Node: Commands For Moving382311
|
||||
Node: Commands For History384362
|
||||
Node: Commands For Text389356
|
||||
Node: Commands For Killing393005
|
||||
Node: Numeric Arguments396038
|
||||
Node: Commands For Completion397177
|
||||
Node: Keyboard Macros401368
|
||||
Node: Miscellaneous Commands402056
|
||||
Node: Readline vi Mode408094
|
||||
Node: Programmable Completion409001
|
||||
Node: Programmable Completion Builtins416781
|
||||
Node: A Programmable Completion Example427533
|
||||
Node: Using History Interactively432781
|
||||
Node: Bash History Facilities433465
|
||||
Node: Bash History Builtins436470
|
||||
Node: History Interaction441494
|
||||
Node: Event Designators445114
|
||||
Node: Word Designators446468
|
||||
Node: Modifiers448228
|
||||
Node: Installing Bash450036
|
||||
Node: Basic Installation451173
|
||||
Node: Compilers and Options454895
|
||||
Node: Compiling For Multiple Architectures455636
|
||||
Node: Installation Names457328
|
||||
Node: Specifying the System Type459437
|
||||
Node: Sharing Defaults460154
|
||||
Node: Operation Controls460827
|
||||
Node: Optional Features461785
|
||||
Node: Reporting Bugs473004
|
||||
Node: Major Differences From The Bourne Shell474348
|
||||
Node: GNU Free Documentation License491197
|
||||
Node: Indexes516374
|
||||
Node: Builtin Index516828
|
||||
Node: Reserved Word Index523655
|
||||
Node: Variable Index526103
|
||||
Node: Function Index543018
|
||||
Node: Concept Index556802
|
||||
|
||||
End Tag Table
|
||||
|
||||
|
||||
Reference in New Issue
Block a user