@ (at sign) Command
The @ command allows you to execute DGMGRL commands stored in script files.
You can put a sequence of commands into a script file and then use the @ command to execute the file. The commands contained in the script are executed sequentially.
Format
From within DGMGRL, the syntax is as follows:
DGMGRL> @<script_file_name>
Command Parameters
| Flag | Description |
|---|---|
| -echo | Prints all the commands in the script along with their execution results. |
Usage Notes
The script that you execute with this command must meet the following qualifications:
-
DGMGRL must be able to access the script; otherwise the command fails because DGMGRL cannot open the file.
-
Every DGMGRL command included in the script must end with a semi-colon.
-
Recursive @ command execution is allowed, but the limit of recursive levels is 20. If the recursive level reaches 20, then the execution is terminated and none of the unexecuted commands are run. Therefore, self-recursive execution of the @ command (for example, putting an @abc.script command in abc.script itself) should be used with caution.
-
If there is a
START OBSERVERcommand in the script, then any commands that come after it are ignored because theSTART OBSERVERcommand turns the DGMGRL session into an observer.The
START OBSERVER IN BACKGROUNDcommand is treated as a normal command; that is, any commands that come after it are executed. -
Comment lines are permitted in the script, but they must be terminated with a semi-colon. For example the following comments would be allowed in a script:
REM Hello World; -- Hello Again!;The double dash must be followed by a space character before the comment text.