User`s guide

5-14
User’s Guide
By default, both the input and output for all commands executed from a batch script are
echoed to the console. Display of commands read from a batch file can be suppressed via
the echo –off command (see echo). If output for a command is redirected to a file, then
that output is not displayed on the console. Note that commands executed from a batch
script are not saved by the Shell for DOSkey history (up–arrow command recall).
Error Handling in Batch Scripts
By default, if an error is encountered during the execution of a command in a batch script,
the script will continue to execute.
The lasterror Shell variable is provided allow batch scripts to test the results of the most
recently executed command using the if command. This variable is not an environment
variable, but is a special variable maintained by the Shell for the lifetime of that instance of
the Shell.
Comments in Script Files
Comments can be embedded in batch scripts. The # character on a line is used to denote
that all characters on the same line and to the right of the # are to be ignored by the Shell.
Comments are not echoed to the console.
EFI Shell Commands
Most Shell commands can be invoked from the EFI Shell prompt. However there are
several commands that are only available for use from within batch script files.
Note:
The “Batch–only” column indicates if the command is only available from within script files.
The following sections provide more details on each of the individual commands.
Command help command_name displays the details of the command_name .