Open System Services Shell and Utilities Reference Manual (G06.29+, H06.08+, J06.03+)
User Commands (s) sh(1)
! (exclamation point)
The process number of the last background command invoked.
ERRNO The value of errno as set by the most recently failed system call. This value is system
dependent and is intended for debugging purposes.
LINENO
The line number of the current line within the script or function being executed.
OLDPWD
The previous working directory set by the cd command.
OPTARG
The value of the last option argument processed by the getopts special command.
OPTIND
The index of the last option argument processed by the getopts special command.
PPID The process number of the parent of the shell.
PWD The present working directory set by the cd command.
RANDOM
Each time this parameter is referenced, a random integer, uniformly distributed
between 0 and 32767, is generated. The sequence of random numbers can be initial-
ized by assigning a numeric value to RANDOM.
REPLY This parameter is set by the select statement and by the read special command when
no arguments are supplied.
SECONDS
Each time this parameter is referenced, the number of seconds since shell invocation is
returned. If this parameter is assigned a value, then the value returned upon reference
will be the value that was assigned plus the number of seconds since the assignment.
The following parameters are used by the shell:
CDPATH
The search path for the cd command.
COLUMNS
If this variable is set, the value is used to define the width of the edit window for the
shell edit modes and for printing select lists.
EDITOR
If the value of this variable ends in vi and the VISUAL variable is not set, then the
corresponding option (see set under Special sh Commands) will be turned on.
ENV If this parameter is set, then parameter substitution is performed on the value to gen-
erate the pathname of the script that will be executed when the shell is invoked. (See
Invocation.) This file is typically used for alias and function definitions.
FCEDIT
The default editor name for the fc command.
527188-021 Hewlett-Packard Company 8−27