mirror of
https://github.com/freebsd/freebsd-src.git
synced 2026-10-28 11:25:21 +01:00
sdiff.1: Document exit status and --help
MFC after: 3 days Approved by: bnovkov (mentor) Sponsored by: fme AG Differential Revision: https://reviews.freebsd.org/D59927
This commit is contained in:
1 parent
30ed27ff25
commit
14c7492637
2 files changed
+23
-1
No files matched your search
+22
-1
@@ -3,7 +3,7 @@
|
||||
.\" Written by Raymond Lai <[email protected]>.
|
||||
.\" Public domain.
|
||||
.\"
|
||||
.Dd February 16, 2024
|
||||
.Dd September 23, 2026
|
||||
.Dt SDIFF 1
|
||||
.Os
|
||||
.Sh NAME
|
||||
@@ -17,6 +17,8 @@
|
||||
.Op Fl w Ar width
|
||||
.Ar file1
|
||||
.Ar file2
|
||||
.Nm sdiff
|
||||
.Fl -help
|
||||
.Sh DESCRIPTION
|
||||
.Nm
|
||||
displays two files side by side,
|
||||
@@ -85,6 +87,8 @@ Print a maximum of
|
||||
.Ar width
|
||||
characters on each line.
|
||||
The default is 130 characters.
|
||||
.It Fl -help
|
||||
Print the usage message and exit.
|
||||
.El
|
||||
.Pp
|
||||
Options passed to
|
||||
@@ -153,6 +157,23 @@ Specifies a directory for temporary files to be created.
|
||||
The default is
|
||||
.Pa /tmp .
|
||||
.El
|
||||
.Sh EXIT STATUS
|
||||
The
|
||||
.Nm
|
||||
utility exits with one of the following values:
|
||||
.Pp
|
||||
.Bl -tag -width Ds -offset indent -compact
|
||||
.It 0
|
||||
No differences were found.
|
||||
.It 1
|
||||
Differences were found.
|
||||
.It >1
|
||||
An error occurred.
|
||||
.El
|
||||
.Pp
|
||||
The
|
||||
.Fl -help
|
||||
option exits with a status of 0.
|
||||
.Sh SEE ALSO
|
||||
.Xr cmp 1 ,
|
||||
.Xr diff 1 ,
|
||||
|
||||
@@ -117,6 +117,7 @@ static struct option longopts[] = {
|
||||
|
||||
static const char *help_msg[] = {
|
||||
"usage: sdiff [-abdilstW] [-I regexp] [-o outfile] [-w width] file1 file2\n",
|
||||
" sdiff --help\n",
|
||||
"-l, --left-column: only print the left column for identical lines.",
|
||||
"-o OUTFILE, --output=OUTFILE: interactively merge file1 and file2 into outfile.",
|
||||
"-s, --suppress-common-lines: skip identical lines.",
|
||||
|
||||
Reference in new issue
Block a user