88 lines
2.3 KiB
Groff
88 lines
2.3 KiB
Groff
.\" Copyright (c) 2024 DTB <trinity@trinity.moe>
|
||
.\" Copyright (c) 2024–2025 Emma Tebibyte <emma@tebibyte.media>
|
||
.\"
|
||
.\" This work is licensed under CC BY-SA 4.0. To see a copy of this license,
|
||
.\" visit <http://creativecommons.org/licenses/by-sa/4.0/>.
|
||
.\"
|
||
.TH FILEIS 1 2025-02-24 "Harakit X.X.X"
|
||
.SH NAME
|
||
fileis \(en scrutinize file properties
|
||
.SH SYNOPSIS
|
||
|
||
fileis
|
||
.RB [ -LSbcdefgkprsuwx ]
|
||
.B file...
|
||
.\"
|
||
.SH DESCRIPTION
|
||
|
||
Determine if files comply with requirements. If the given files comply with the
|
||
specified requirements, the program will exit successfully. Otherwise, it exits
|
||
unsuccessfully.
|
||
.\"
|
||
.SH OPTIONS
|
||
|
||
.IP \fB-L\fB
|
||
Requires the given files to exist and be symbolic links.
|
||
.IP \fB-S\fP
|
||
Requires the given files to exist and be sockets.
|
||
.IP \fB-b\fP
|
||
Requires the given files to exist and be block special files.
|
||
.IP \fB-c\fP
|
||
Requires the given files to exist and be character special files.
|
||
.IP \fB-d\fP
|
||
Requires the given files to exist and be directories.
|
||
.IP \fB-e\fP
|
||
Requires the given files to exist, and is redundant to any other option.
|
||
.IP \fB-f\fP
|
||
Requires the given files to exist and be regular files.
|
||
.IP \fB-g\fP
|
||
Requires the given files to exist and have their set group ID flags set.
|
||
.IP \fB-k\fP
|
||
Requires the given files to exist and have their sticky bit set.
|
||
.IP \fB-p\fP
|
||
Requires the given files to exist and be named pipes.
|
||
.IP \fB-r\fP
|
||
Requires the given files to exist and be readable.
|
||
.IP \fB-u\fP
|
||
Requires the given files to exist and have their set user ID flags set.
|
||
.IP \fB-w\fP
|
||
Requires the given files to exist and be writable.
|
||
.IP \fB-x\fP
|
||
Requires the given files to exist and be executable.
|
||
.\"
|
||
.SH DIAGNOSTICS
|
||
|
||
When invoked incorrectly, a debug message will be printed and the program will
|
||
exit with the appropriate
|
||
.BR sysexits.h (3)
|
||
error code.
|
||
.\"
|
||
.SH RATIONALE
|
||
|
||
The
|
||
.BR test (1p)
|
||
utility contains functionality that was broken out into separate programs. Thus,
|
||
the scope of this program is narrower than it. Notably, the
|
||
.B -h
|
||
option is now invalid and therefore shows usage information instead of being an
|
||
alias to the modern
|
||
.B -L
|
||
option.
|
||
.\"
|
||
.SH AUTHOR
|
||
|
||
Written by DTB
|
||
.MT trinity@trinity.moe
|
||
.ME .
|
||
.\"
|
||
.SH COPYRIGHT
|
||
|
||
Copyright \(co 2024 DTB. License AGPLv3+: GNU AGPL version 3 or later
|
||
<https://gnu.org/licenses/agpl.html>.
|
||
.\"
|
||
.SH SEE ALSO
|
||
.BR access (3p),
|
||
.BR chown (1p),
|
||
.BR lstat (3p),
|
||
.BR test (1p)
|