Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

koitsu/errno

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

17 Commits

Repository files navigation

errno

errno is a Perl-based error code lookup utility very similar to MySQL's perror utility, or FreeBSD 8.0-and-newer's perror utility, but with some added features.

It has no dependencies, instead relying on error codes and names provided entirely from the built-in Perl Errno module.

If your OS offers some error codes which are not shown, then the issue is with Perl/Errno and not this utility.

Usage

Provide one or more error codes as arguments to the utility. Invalid syntax or unknown error codes will emit an error to stdout and will exit with a status of 1.

The -l (lowercase-ELL) or --list flag can be used to list all known error codes and descriptions, including names (ex. ENOENT). This flag

The -s or --short flag can be used to omit Error code XXX and error code names from output, making it behave similar to FreeBSD's perror utility.

The -h, --help, or -? flag will display usage syntax.

Examples

$ errno 9 4 13
Error code 9: Bad file descriptor (EBADF)
Error code 4: Interrupted system call (EINTR)
Error code 13: Permission denied (EACCES)
$ errno --short 4
Interrupted system call
$ errno --list | head -5
Error code 1: Operation not permitted (EPERM)
Error code 2: No such file or directory (ENOENT)
Error code 3: No such process (ESRCH)
Error code 4: Interrupted system call (EINTR)
Error code 5: Input/output error (EIO)
$ errno 12345 ; echo $?
ERROR: Error code 12345 unknown. Try using --list.
1

License

errno is released under the 2-clause BSD license ("FreeBSD License") per LICENSE.

About

Perl-based errno lookup utility (similar to MySQL perror)

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

Contributors

Languages

AltStyle によって変換されたページ (->オリジナル) /