Command Variables
Variables are similar to aliases, but can be used in any part of a command. A variable has a name and a value. When a variable name is encountered in a command, ODB replaces it with the corresponding value.
Note: Variable names must not begin with a digit (0–9).
A variable is referenced in a command using one of the following syntaxes:
$<var>%<var>%
If <var> is not defined in ODB proper, the system will look for a shell variable of the same name and replace the variable by the corresponding value. This can be used to reference shell-based preferences.
Table 27: Variable Commands
| Command | Description |
|---|---|
| setvar | Defines a variable, or displays all defined variables. |
| unsetvar | Undefines a variable. |
Variable references are not expanded when defining new variables or aliases. The value expansion will take place when the variables are actually used.
Commands
Descriptions of the ODB commands follow.