Index

This index / glossary / quick-reference lists many of the important topics covered in the text. Terms are arranged in approximate sorting order, reshuffled as necessary for enhanced clarity.

Note that commands are indexed in Part 4.

* * *

^ Beginning-of-line, in a Regular Expression

~ Tilde

= Equals sign

< Left angle bracket

> Right angle bracket

| Pipe, a device for passing the output of a command to another command or to the shell

|| Or logical operator

- Dash

; Semicolon, as command separator

;; Double-semicolon, terminator in a case option

: Colon, equivalent to the true Bash builtin

! Negation operator, inverts exit status of a test or command

? Question mark, in a Regular Expression

// Double forward slash, behavior of cd command toward

. Dot / period

' ... ' Single quotes, "strong" quoting

" ... " Double quotes, "weak" quoting

( ... ) Parentheses, to group commands; starts a subshell

(( ... )) Double parentheses, in arithmetic expansion

[ Left bracket, test construct

[[ ... ]] Double brackets, extended test construct

$ Anchor, in a Regular Expression

$ Prefix to a variable name

$( ... ) Command substitution, setting a variable with output of a command, using parentheses notation

` ... ` Command substitution, using backquotes notation

${ ... }

\ Escape the following character

\< ... \> Angle brackets, escaped, word boundary in a Regular Expression

# Hashmark, special symbol beginning a script comment

#! Sha-bang, special string starting a shell script

* Asterisk

% Percent sign

+ Character match, in an extended Regular Expression

++ C-style variable increment, within double parentheses

* * *

Shell Variables

$_ Last argument to previous command

$- Flags passed to script, using set

$! Process ID of last background job

$? Exit status of a command

$@ All the positional parameters, as separate words

$* All the positional parameters, as a single word

$$ Process ID of the script

$# Number of arguments passed to a function, or to the script itself

$0 Filename of the script

* * * * * *

Advanced Bash Scripting Guide, where to download

Alias

And list

And list, to supply default command-line argument

Angle brackets, escaped, \< . . . \> word boundary in a Regular Expression

Anonymous here document, using :

Arithmetic expansion

Arithmetic operators

Arrays

awk field-oriented text processing language

* * *

Backquotes, used in command substitution

Bash

$BASH_SUBSHELL

Basic commands, external

Batch processing

Bison utility

Bitwise operators

Blocks of code

Brace expansion

Brackets

break loop control command

Builtins in Bash

* * *

case and esac

cat, piping the output of, to a read

cat scripts

Child processes

Colon, : , equivalent to the true Bash builtin

Colorizing scripts

Comma operator, linking commands or operations

Command substitution

Commenting out blocks of code

Compound comparison operators

continue loop control command

Control characters

Curly brackets, in find command

* * *

Daemons, in UNIX-type OS

dd command, thread

Decimal number, Bash interprets numbers as

declare builtin

Default parameters

/dev directory

dialog, utility for generating dialog boxes in a script

$DIRSTACK directory stack

Disabled commands, in restricted shells

do keyword, begins execution of commands within a loop

done keyword, terminates a loop

DOS batch files, converting to shell scripts

dot files, "hidden" setup and configuration files

Double brackets [[ ... ]] test construct

Double quotes (" ... ") "weak" quoting

* * *

-e File exists test command

echo, in combination with grep

elif, Contraction of else and if

Environmental variables

-eq , equality integer comparison test

Escaped characters, special meanings of

$EUID, Effective user ID

eval, Evaluate expression(s), with variable expansion

exec command, using in redirection

Exit and Exit status

Export, to make available variables to child processes

expr, Expression evaluator

Extended Regular Expressions

* * *

File descriptor

Floating point numbers, Bash does not recognize

Forking a child process

for loops

Functions

* * *

Globbing, filename expansion

-gt , greater-than integer comparison test

$GROUPS, Groups user belongs to

* * *

Hashing, creating lookup keys in a table

Here documents

$HOME, user's home directory

$HOSTNAME, system host name

* * *

if [ condition ]; then ... test construct

$IFS, Internal field separator variable, by which Bash determines field boundaries within strings

Integer comparison operators

in, keyword preceding [list] in a for loop

Initialization table, /etc/inittab

Interactive script, test for

I/O redirection

Indirect referencing of variables

* * *

Keywords

killall script in /etc/rc.d/init.d

* * *

Limit string, in a here document

$LINENO, variable indicating the line number where it appears in a script

Link, file (using ln command)

List constructs (and lists, or lists, etc.)

Local variables

Logical operators (&&, ||, etc.)

Logout file, the ~/.bash_logout file

Loopback devices, in /dev directory

-lt , less-than integer comparison test

* * *

$MACHTYPE, Machine type

Magic number, marker at the head of a file indicating the file type

Makefile, file containing the list of dependencies used by make command

* * *

Named pipe, a temporary FIFO buffer

-ne, not-equal-to integer comparison test

Negation operator, !, reverses the sense of a test

Noclobber, -C option to Bash to prevent overwriting of files

* * *

$OLDPWD Previous working directory

Options, passed to shell or script on command line or by set command

Or logical operator, ||

* * *

Parameters, default (in parameter substitution)

Parameter substitution

Parent / child process problem, a child process cannot export variables to a parent process

Parentheses, used to group commands

$PATH, the path (location of system binaries)

Perl programming language

Pipe, | , a device for passing the output of a command to another command or to the shell

Positional parameters

POSIX, Portable Operating System Interface / UNIX

$PPID, process ID of parent process

Prepending lines at beginning of a file (script example)

Process

Process substitution

Prompt

Pseudo-code, as problem-solving method

$PWD, Current working directory

* * *

Question mark, ? , in a Regular Expression

Quoting a character string

* * *

Random numbers

read, problems with piping echo to

Recursion, and local variables

Redirection

Regular Expressions

$REPLY, Default value associated with read command

Restricted shell, shell (or script) with certain commands disabled

return, command that terminates a function

* * *

Scope of a variable, definition

Script options, set at command line

Secondary prompt, $PS2

sed, pattern-based programming language

select, construct for menu building

Semicolon required, when do keyword is on the first line of loop

Shell script, definition of

Shell wrapper, script embedding a command or utility

shift, reassigning positional parameters

$SHLVL, shell level, depth to which the shell (or script) is nested

Signal, a message sent to a process

Single quotes (' ... ') "strong" quoting

Socket, a communication node associated with an I/O port

Special characters

Startup files, Bash

Strings

"Strong" quoting (' ... ')

Subshell

suid (set user id) file flag

Symbolic links

* * *

Test constructs

test command, Bash builtin

$TMOUT, Timeout interval

Trap, specifying an action upon receipt of a signal

typeset builtin

* * *

$UID, User ID number

until loop, until [ condition-is-true ]; do

* * *

Variables

* * *

wait command, use of to remedy script hang

"Weak" quoting (" ... ")

while loop, while [ condition ]; do

Whitespace, spaces, tabs, and newline characters

* * *

xargs, Filter for assembling arguments

* * *

Zombie, a process that has terminated, but not yet been killed by its parent process