COHERENT manpages
This page displays the COHERENT manpage for wait [Await completion of background process].
List of available manpages
Index
wait -- Command Await completion of background process wait [pid] Typing the character `&' after a command tells the shell sh to execute it as a background (or detached) process; otherwise, it is executed as a foreground process. You can perform other tasks while a background process is being executed. The shell prints the process id number of each background process when it is invoked. ps reports on currently active processes. The command wait tells the shell to suspend execution until the child process with the given pid is completed. If no pid is given, wait suspends execution until all background processes are completed. If the process with the given pid is not a child process of the current shell, wait returns immediately. The shell executes wait directly. See Also commands, ksh, ps, sh Notes If a subshell invokes a background process and then terminates, wait returns immediately rather than waiting for the termination of the grandchild process.