The topic of shell programming doesn't lend itself as neatly to a command-by-command reference as other subjects covered in this book. (There are a whole lot of little commands, most of which have few or no arguments.) Consequently, I'm going to break with the traditions of this book a little bit and arrange this chapter by subtopic.
The notation used in this chapter may be a wee bit confusing. Here are some examples that hopefully might clear things up: |
Notation | Means |
<Tab> | Press the Tab key on the keyboard. Do not try to type the letter sequence T-a-b. |
<Ctrl>-P | Press the Ctrl key and the P key at the same time. |
<Meta>-r | Press the meta key (on my keyboard it's the <Esc> key; yours may be different) and the r key at the same time. |
The subtopics covered in this chapter include the following:
Invoking bash | Command line options for bash. |
Startup Files | Conditions under which startup or shutdown files are sourced. |
Aliases | Set and unset command line aliases. |
Command History | Access and manipulate command history. |
Command Completion | How to exploit command completion features. |
Command Line Editing | How to manipulate the current command line. |
Word Designators | How to specify individual words on a command line. |
Shell Variables | Listing of shell variables. |
Shell Prompt | How to customize your shell prompt. |
Shell Arithmetic | Shell arithmetic operators. |
Looping Statements | Shell looping statements. |
Conditional Statements | Syntax and examples. |
Shell Functions | Syntax and examples. |
Builtins | Built-in bash commands. |