Operating System and Environment Access
Operating system commands can be executed from within PV-WAVE without quitting the current PV-WAVE session.
To execute a single operating system command from PV-WAVE, enter the dollar sign ($) followed by the desired operating system command.
Operating System Commands
For example, to see a listing of files in the current directory (under UNIX), at the WAVE> prompt, type:
$ ls
The files in your current directory are displayed. In Windows, type $ dir.
To enter multiple operating system commands and temporarily suspend PV-WAVE, type:
SPAWN
The operating system prompt appears.
Now you can enter operating system commands just as you normally would.
To exit the operating system and return to PV-WAVE, at the operating system prompt, enter (for UNIX and Windows machines):
exit
OS and Environment Access Commands lists some common OS and environment access commands that you may find useful when using PV‑WAVE.
| Command | Description |
|---|---|
| $ | By itself from the WAVE> prompt, spawns a child process to the operating system prompt. If followed by an operating system command, executes it then immediately returns to WAVE> prompt. Not for use in programs. |
| SPAWN | Spawns a child process to execute commands. Output generated by commands can be captured in a PV-WAVE variable. Can be used in programs (unlike $). |
| GETENV | Get value of an environment variable. |
| SETENV | Set value of an environment variable. |
| ENVIRONMENT | Returns a string array containing all the environment strings for the PV-WAVE process. (UNIX/Windows) |
| CD | Change current directory. |
| PUSHD | Push directory to top of LIFO directory stack. |
| POPD | Pop directory from top of LIFO directory stack. |
| PRINTD | List all directories in LIFO (Last-In-First-Out) directory stack, and current directory. |
| PWD | Prints the working directory. |