$prompt = $ENV{'PSH_PROMPT'} || 'psh> ';
This line is used to define our initial prompt. Either we are going to
pull the prompt from the environment, or, if that has no value, we are
going to use a default. This line is positioned near the top of the
script because we may wish to reconfigure the default prompt someday.
Recall:
- The environment is stored in a special associative array,
%ENV
. $ENV{'PSH_PROMPT'}
is going to look
up the value associated with the PSH_PROMPT
variable
in the environment.
||
means "or".
'psh>'
is the default designated in the goals.