Jump to content

Exit (command)

From Alfawiki
exit command
Company typeCommand
IndustryComputing / Operating systems
ProductsShell exit command

In the realm of computing, the exit command is widely utilized within numerous operating system CLI shells and scripting languages to end the execution of a shell or program. When run in an interactive shell environment, it effectively logs the user out from their active session or severs the terminal connection. Optionally, it can provide an exit code, typically represented as an integer, which is returned to the parent process.

Implementations

The exit command finds support across a broad spectrum of operating systems and shell environments, such as Microsoft MSX-DOS version 2, IBM OS/2, DR FlexOS, HP’s MPE/iX, KolibriOS, SymbOS, the Windows command interpreter (cmd.exe), the sh, the ksh, as well as scripting languages like Perl, AWK, PHP, TCL, and Microsoft's PowerShell.

Within the context of MS-DOS, this command has been present since its second release. Other DOS-based systems, including DR DOS 6.0 and Datalight’s ROM-DOS, also incorporate this functionality. Furthermore, the open-source MS-DOS emulator known as DOSBox implements the exit command.

The numerical computing platform MATLAB provides an exit function that performs a comparable role.

See also

Further reading

External links