The Bourne Shell
The AWK Pattern Scanning and Processing Language
Back to the introduction
The following sections list the set of variables and special characters supported by
both
| Name | Meaning |
|---|---|
| The full pathname of your home directory | |
| A list of directories to search for commands | |
| The full pathname of your mailbox | |
| Your username | |
| The full pathname of your login shell | |
| The type of your terminal |
| Name | Value |
|---|---|
| The name of the shell script | |
| A list of all command-line arguments |
Some characters are processed specially by the shell; these are known as
| Metacharacter | Meaning |
|---|---|
| Output redirection; writes standard output to a file | |
| Output redirection; appends standard output to a file | |
| Input redirection; reads standard input from a file | |
| Command substitution; replaced by the output from |
|
| Pipe symbol; sends the output of one process to the input of another | |
| If appears on the first line, following it is the pathname of the shell. If appears on any other line, all characters that follow up to a new line are treated as comments by the shell | |
| Expands the value of a variable |
The following wildcards are supported by both csh and sh:
| Wildcard | Meaning |
|---|---|
| Matches any string, including the empty string | |
| Matches any single character | |
| Matches any character in the range specified by |
|
| Matches any character or string that starts with the character specified by |
The single quotes and double quotes have the same functions in both csh and sh:
Commands executed in either csh or sh always return an exit status. An exit value of 0 indicates
the command has completed successfully, and a nonzero exit value indicates failure. All built-in commands
(e.g.,
The Bourne Shell
The AWK Pattern Scanning and Processing Language
Back to the introduction
Copyright (C) 2000 - 2002, The University of British Columbia