test.1: convert to mandoc and some fixes

- sort flags.
- fix 2 typos.
This commit is contained in:
Hiltjo Posthuma 2015-01-30 22:52:01 +01:00
parent b3c5b206e7
commit a576a74635
1 changed files with 51 additions and 72 deletions

121
test.1
View File

@ -1,96 +1,75 @@
.TH TEST 1 sbase\-VERSION .Dd January 30, 2015
.SH NAME .Dt TEST 1 sbase\-VERSION
test \- check file types and compare values .Os
.SH SYNOPSIS .Sh NAME
.B test .Nm test
.RB EXPRESSION .Nd check file types and compare values
.SH DESCRIPTION .Sh SYNOPSIS
.B Exit with the status determined by EXPRESSION. .Nm
.SH OPTIONS .Ar EXPRESSION
.TP .Sh DESCRIPTION
.B ! EXPRESSION Exit with the status determined by
invert EXPORESSION .Ar EXPRESSION .
.TP .Sh OPTIONS
.B \-b FILE .Bl -tag -width Ds
.It ! Ar EXPRESSION
invert EXPRESSION
.It Fl b Ar FILE
FILE exists and is block special FILE exists and is block special
.TP .It Fl c Ar FILE
.B \-c FILE
FILE exists and is character special FILE exists and is character special
.TP .It Fl d Ar FILE
.B \-d FILE
FILE exists and is a directory FILE exists and is a directory
.TP .It Fl e Ar FILE
.B \-e FILE
FILE exists FILE exists
.TP .It Fl f Ar FILE
.B \-f FILE FILE exists and is a regular file
ILE exists and is a regular file .It Fl g Ar FILE
.TP
.B \-g FILE
FILE exists and is set-group-ID FILE exists and is set-group-ID
.TP .It Fl h Ar FILE
.B \-k FILE FILE exists and is a symbolic link (same as
.Fl L )
.It Fl k Ar FILE
FILE exists and its sticky bit is set FILE exists and its sticky bit is set
.TP .It Fl L Ar FILE
.B \-h FILE FILE exists and is a symbolic link (same as
FILE exists and is a symbolic link (same as -L) .Fl h )
.TP .It Fl n Ar STRING
.B \-L FILE
FILE exists and is a symbolic link (same as -h)
.TP
.B \-n STRING
the length of STRING is nonzero the length of STRING is nonzero
.TP .It Fl p Ar FILE
.B \-p FILE
FILE exists and is a named pipe FILE exists and is a named pipe
.TP .It Fl r Ar FILE
.B \-r FILE
FILE exists and read permission is granted FILE exists and read permission is granted
.TP .It Fl S Ar FILE
.B \-S FILE
FILE exists and is a socket FILE exists and is a socket
.TP .It Fl s Ar FILE
.B \-s FILE
FILE exists and has a size greater than zero FILE exists and has a size greater than zero
.TP .It Fl t Ar FD
.B \-t FD
file descriptor FD is opened on a terminal file descriptor FD is opened on a terminal
.TP .It Fl u Ar FILE
.B \-u FILE
exists and its set-user-ID bit is set exists and its set-user-ID bit is set
.TP .It Fl w Ar FILE
.B \-w FILE
FILE exists and write permission is granted FILE exists and write permission is granted
.TP .It Fl x Ar FILE
.B \-x FILE
FILE exists and execute (or search) permission is granted FILE exists and execute (or search) permission is granted
.TP .It Fl z Ar STRING
.B \-z STRING
the length of STRING is zero the length of STRING is zero
.TP .It s1 = s2
.B s1 = s2
True if the strings s1 and s2 are identical True if the strings s1 and s2 are identical
.TP .It s1 != s2
.B s1 != s2
True if the strings s1 and s2 are not identical True if the strings s1 and s2 are not identical
.TP .It s1
.B s1
True if s1 is not the null string True if s1 is not the null string
.TP .It n1 -eq n2
.B n1 -eq n2
True if the integers n1 and n2 are equal True if the integers n1 and n2 are equal
.TP .It n1 -ne n2
.B n1 -ne n2
True if the integers n1 and n2 are not equal True if the integers n1 and n2 are not equal
.TP .It n1 -gt n2
.B n1 -gt n2
True if the integer n1 is greater than the integer n2 True if the integer n1 is greater than the integer n2
.TP .It n1 -ge n2
.B n1 -ge n2
True if the integer n1 is great than or equal to the integer n2 True if the integer n1 is great than or equal to the integer n2
.TP .It n1 -lt n2
.B n1 -lt n2
True if the integer n1 is less than the integer n2 True if the integer n1 is less than the integer n2
.TP .It n1 -le n2
.B n1 -le n2
True if the integer n1 is less than or equal to the integer n2 True if the integer n1 is less than or equal to the integer n2
.El