module TTY::Exit::Code
All reserved exit codes as constants
Constants
- ABORT
This indicates that program received SIGABRT signal.
- ALARM
This indicates that program received SIGALARM signal.
- BASE
The start base code to reduce possibility of clashing with other exit statuses that programs may already run.
- BUS_ERROR
This indicates that program received SIGBUS signal. Access to an undefined portion of a memory object
- CANNOT_EXECUTE
Command invoked cannot execute. This may be due to permission issues.
- CANT_CREATE
A (user specified) output file cannot be created.
- COMMAND_NOT_FOUND
“command not found”, possible typos in shell command or unrecognized characters
- CONFIG_ERROR
Something was found in an unconfigured or misconfigured state.
- DATA_ERROR
The input data was incorrect in some way. This should only be used for user's data & not system files.
- ERROR
Catchall for general errors
- HANGUP
This indicates that program received SIGHUP signal. It means that the controlling pseudo or virtual terminal has been closed.
- ILLEGAL_INSTRUCTION
This indicates that program received SIGQUIT signal.
- INTERRUPT
This indicates that program received SIGINT signal. An interrupt signal that by default this causes the process to terminate.
- INVALID_ARGUMENT
Exit
takes only integer args in the range 0 - 255, e.g. exit 3.14159 is invalid.- IO_ERROR
An error occurred while doing I/O on some file.
- KILL
This indicates that program received SIGKILL signal.
- MEMORY_ERROR
This indicates that program received SIGSEGV signal.
- NO_HOST
The host specified did not exist. This is used in mail addresses or network requests.
- NO_INPUT
An input file (not a system file) did not exist or was not readable.
- NO_PERM
You did not have sufficient permission to perform the operation. This is not intended for file system problems, which should use
NO_INPUT
orCANT_CREATE
, but rather for higher level permissions.- NO_USER
The user specified did not exist. This might be used for mail addresses or remote logins.
- PIPE
This indicates that program received SIGPIPE signal.
- PROTOCOL
The remote system returned something that was 'not possible' during a protocol exchange.
- QUIT
This indicates that program received SIGQUIT signal.
- SERVICE_UNAVAILABLE
A service is unavailable. This can occur if a support program or file does not exist. This can also be used as a catchall message when something you wanted to do doesn't work, but you don't know why.
- SHELL_MISUSE
Missing keyword or command, or permission problem (and diff return code on a failed binary file comparison).
- SIGNAL_BASE
The start base code for the system interrupt signals.
- SOFTWARE_ERROR
An internal software error has been detected. This should be limited to non-operating system related errors as possible.
- SUCCESS
No errors
- SYSTEM_ERROR
An operating system error has been detected. This is intended to be used for such things as “cannot fork”, “cannot create pipe”, or the like. It includes things like getuid returning a user that does not exist in the passwd file.
- SYSTEM_FILE_MISSING
Some system file (e.g., /etc/passwd, /etc/utmp, etc.) does not exist, cannot be opened, or has some sort of error (e.g., syntax error).
- TEMP_FAIL
Temporary failure, indicating something that is not really an error. For example that a mailer could not create a connection, and the request should be reattempted later.
- TRACE_TRAP
This indicates that program received SIGTRAP signal.
- USAGE_ERROR
The command was used incorrectly, e.g., with the wrong number of arguments, a bad flag, a bad syntax in a parameter, or whatever.
- USER1
This indicates that program received SIGUSR1 signal.
- USER2
This indicates that program received SIGUSR2 signal.