Sync program's usage() with manpage's SYNOPSIS.

This commit is contained in:
ru 2005-05-21 09:55:10 +00:00
parent 5a7d45e3b5
commit 0491ba1f63
39 changed files with 62 additions and 61 deletions

View File

@ -86,7 +86,7 @@ static void
usage(void) usage(void)
{ {
fprintf(stderr, "usage: asa [file...]\n"); fprintf(stderr, "usage: asa [file ...]\n");
exit(1); exit(1);
} }

View File

@ -164,7 +164,8 @@ main(int argc, char **argv)
static void static void
usage(void) usage(void)
{ {
fprintf(stderr, "usage: brandelf [-f ELF ABI number] [-v] [-l] [-t string] file ...\n"); (void)fprintf(stderr,
"usage: brandelf [-lv] [-f ELF_ABI_number] [-t string] file ...\n");
exit(1); exit(1);
} }

View File

@ -33,17 +33,12 @@
.Nd POSIX.2 C language compiler .Nd POSIX.2 C language compiler
.Sh SYNOPSIS .Sh SYNOPSIS
.Nm .Nm
.Op Fl c .Op Fl cEgOs
.Op Fl D Ar name Ns Op = Ns Ar value .Oo Fl D Ar name Ns Oo = Ns Ar value Oc Oc ...
.Ar ... .Oo Fl I Ar directory Oc ...
.Op Fl E .Oo Fl L Ar directory Oc ...
.Op Fl g
.Op Fl I Ar directory ...
.Op Fl L Ar directory ...
.Op Fl o Ar outfile .Op Fl o Ar outfile
.Op Fl O .Oo Fl U Ar name Oc ...
.Op Fl s
.Op Fl U Ar name ...
.Ar operand ... .Ar operand ...
.Sh DESCRIPTION .Sh DESCRIPTION
This is the name of the C language compiler as required by the This is the name of the C language compiler as required by the

View File

@ -102,8 +102,8 @@ static void
usage(void) usage(void)
{ {
fprintf(stderr, fprintf(stderr,
"usage: c89 [-c] [-D name[=value]] [...] [-E] [-g] [-I directory ...]\n" "usage: c89 [-cEgOs] [-D name[=value]] ... [-I directory] ... [-L directory] ...\n"
" [-L directory ...] [-o outfile] [-O] [-s] [-U name ...] operand ...\n" " [-o outfile] [-U name] ... operand ...\n"
"\n" "\n"
" where operand is one or more of file.c, file.o, file.a\n" " where operand is one or more of file.c, file.o, file.a\n"
" or -llibrary\n"); " or -llibrary\n");

View File

@ -35,13 +35,12 @@
.Sh SYNOPSIS .Sh SYNOPSIS
.Nm .Nm
.Op Fl cEgs .Op Fl cEgs
.Op Fl D Ar name Ns Op = Ns Ar value .Oo Fl D Ar name Ns Oo = Ns Ar value Oc Oc ...
.Ar ... .Oo Fl I Ar directory Oc ...
.Op Fl I Ar directory ... .Oo Fl L Ar directory Oc ...
.Op Fl L Ar directory ...
.Op Fl o Ar outfile .Op Fl o Ar outfile
.Op Fl O Ar optlevel .Op Fl O Ar optlevel
.Op Fl U Ar name ... .Oo Fl U Ar name Oc ...
.Ar operand ... .Ar operand ...
.Sh DESCRIPTION .Sh DESCRIPTION
This is the name of the C language compiler as required by the This is the name of the C language compiler as required by the

View File

@ -126,9 +126,8 @@ addlib(const char *lib)
void void
usage(void) usage(void)
{ {
fprintf(stderr, (void)fprintf(stderr, "%s\n%s\n",
"usage: c99 [-cEgs] [-D name[=value]] [-I directory] ... [-L directory] ...\n"); "usage: c99 [-cEgs] [-D name[=value]] ... [-I directory] ... [-L directory] ...",
fprintf(stderr, " [-o outfile] [-O optlevel] [-U name] ... operand ...");
" [-o outfile] [-O optlevel] [-U name]... operand ...\n");
exit(1); exit(1);
} }

View File

@ -741,7 +741,8 @@ determine_locale(void)
static void static void
usage(void) usage(void)
{ {
fprintf(stderr, "usage: %s [-fLnrv] [directories...]\n", getprogname()); fprintf(stderr, "usage: %s [-fLnrv] [directories ...]\n",
getprogname());
exit(1); exit(1);
} }

View File

@ -342,7 +342,7 @@ main(int ac, char **av)
static void static void
usage(void) usage(void)
{ {
fprintf(stderr, "usage: colldef [-o out_file] [-I map_dir] [filename]\n"); fprintf(stderr, "usage: colldef [-I map_dir] [-o out_file] [filename]\n");
exit(EX_USAGE); exit(EX_USAGE);
} }

View File

@ -79,6 +79,6 @@ void
usage(void) usage(void)
{ {
(void)fprintf(stderr, "usage: dirname path\n"); (void)fprintf(stderr, "usage: dirname string\n");
exit(1); exit(1);
} }

View File

@ -41,11 +41,11 @@
.Sh SYNOPSIS .Sh SYNOPSIS
.Nm .Nm
.Op Fl H | L | P .Op Fl H | L | P
.Op Fl I Ar mask
.Op Fl a | s | d Ar depth .Op Fl a | s | d Ar depth
.Op Fl c .Op Fl c
.Op Fl h | k | m .Op Fl h | k | m
.Op Fl x .Op Fl x
.Op Fl I Ar mask
.Op Ar .Op Ar
.Sh DESCRIPTION .Sh DESCRIPTION
The The

View File

@ -154,7 +154,8 @@ option(int argc, char **argv)
static void static void
usage(void) usage(void)
{ {
(void)fprintf(stderr, "usage: finger [-46klmpshoT] [login ...]\n"); (void)fprintf(stderr,
"usage: finger [-46gklmpshoT] [user ...] [user@host ...]\n");
exit(1); exit(1);
} }

View File

@ -41,8 +41,8 @@
.Sh SYNOPSIS .Sh SYNOPSIS
.Nm .Nm
.Op Fl c .Op Fl c
.Op Fl s Ar sender
.Op Fl f Ar file .Op Fl f Ar file
.Op Fl s Ar sender
.Op Ar user .Op Ar user
.Sh DESCRIPTION .Sh DESCRIPTION
The The

View File

@ -927,6 +927,6 @@ void
usage(void) usage(void)
{ {
(void)fprintf(stderr, (void)fprintf(stderr,
"usage: fstat [-fmnv] [-p pid] [-u user] [-N system] [-M core] [file ...]\n"); "usage: fstat [-fmnv] [-M core] [-N system] [-p pid] [-u user] [file ...]\n");
exit(1); exit(1);
} }

View File

@ -46,7 +46,7 @@ __FBSDID("$FreeBSD$");
#define SBUFLEN 128 #define SBUFLEN 128
#define USAGE \ #define USAGE \
"usage: ktrdump [-c] [-f] [-q] [-r] [-t] [-e execfile] [-i ktrfile ] [-m corefile] [-o outfile]" "usage: ktrdump [-cfqrt] [-e execfile] [-i ktrfile] [-m corefile] [-o outfile]"
extern char *optarg; extern char *optarg;
extern int optind; extern int optind;
@ -285,5 +285,7 @@ main(int ac, char **av)
static void static void
usage(void) usage(void)
{ {
errx(1, USAGE);
fprintf(stderr, USAGE);
exit(1);
} }

View File

@ -279,6 +279,6 @@ static void
usage(void) usage(void)
{ {
(void)fprintf(stderr, (void)fprintf(stderr,
"usage: lastcomm [-EScesu] [ -f file ] [command ...] [user ...] [tty ...]\n"); "usage: lastcomm [-EScesu] [-f file] [command ...] [user ...] [terminal ...]\n");
exit(1); exit(1);
} }

View File

@ -111,6 +111,6 @@ main(int argc, char *argv[])
static void static void
usage(void) usage(void)
{ {
(void)fprintf(stderr, "usage: mesg [y | n]\n"); (void)fprintf(stderr, "usage: mesg [n | y]\n");
exit(2); exit(2);
} }

View File

@ -170,8 +170,8 @@ static void
usage(void) usage(void)
{ {
(void)fprintf(stderr, "%s\n%s\n", (void)fprintf(stderr, "%s\n%s\n",
"usage: newkey [-u username]", "usage: newkey -h hostname",
" newkey [-h hostname]"); " newkey -u username");
exit(1); exit(1);
} }

View File

@ -109,6 +109,7 @@ void
usage(void) usage(void)
{ {
(void)fprintf(stderr, "usage: nice [-n incr] utility [arguments]\n"); (void)fprintf(stderr,
"usage: nice [-n increment] utility [argument ...]\n");
exit(1); exit(1);
} }

View File

@ -85,7 +85,7 @@ static void
usage(void) usage(void)
{ {
fprintf(stderr, "usage: pathchk [-p] pathname...\n"); fprintf(stderr, "usage: pathchk [-p] pathname ...\n");
exit(1); exit(1);
} }

View File

@ -552,5 +552,5 @@ asciicode(void)
static void static void
usage(void) usage(void)
{ {
(void)fprintf(stderr, "usage: printf format [arg ...]\n"); (void)fprintf(stderr, "usage: printf format [arguments ...]\n");
} }

View File

@ -180,7 +180,7 @@ static void
usage() usage()
{ {
fprintf(stderr, "%s\n%s\n", fprintf(stderr, "%s\n%s\n",
"usage: renice priority [[-p] pid ...] [[-g] pgrp ...] [[-u] user ...]", "usage: renice priority [[-p] pid ...] [[-g] pgrp ...] [[-u] user ...]",
" renice -n increment [[-p] pid ...] [[-g] pgrp ...] [[-u] user ...]"); " renice -n increment [[-p] pid ...] [[-g] pgrp ...] [[-u] user ...]");
exit(1); exit(1);
} }

View File

@ -371,6 +371,6 @@ usage(void)
{ {
(void)fprintf(stderr, (void)fprintf(stderr,
"usage: rsh [-46dn] [-l login] [-t timeout] host [command]\n"); "usage: rsh [-46dn] [-l username] [-t timeout] host [command]\n");
exit(1); exit(1);
} }

View File

@ -213,7 +213,7 @@ allhosts(void)
static void static void
usage(void) usage(void)
{ {
fprintf(stderr, "usage: rup [hosts ...]\n"); fprintf(stderr, "usage: rup [host ...]\n");
exit(1); exit(1);
} }

View File

@ -298,6 +298,6 @@ tcmp(const void *a1, const void *a2)
void void
usage(void) usage(void)
{ {
(void)fprintf(stderr, "usage: ruptime [-alrut]\n"); (void)fprintf(stderr, "usage: ruptime [-alrtu] [host ...]\n");
exit(1); exit(1);
} }

View File

@ -218,7 +218,7 @@ static void
usage(void) usage(void)
{ {
fprintf(stderr, "usage: rusers [-la] [hosts ...]\n"); fprintf(stderr, "usage: rusers [-al] [host ...]\n");
exit(1); exit(1);
} }

View File

@ -117,7 +117,7 @@ main(int argc, char *argv[])
static void static void
usage(void) usage(void)
{ {
fprintf(stderr, "usage: rwall hostname [file]\n"); fprintf(stderr, "usage: rwall host [file]\n");
exit(1); exit(1);
} }

View File

@ -372,7 +372,7 @@ xdr_exports(xdrsp, exp)
static void static void
usage() usage()
{ {
fprintf(stderr, "usage: showmount [-a | -d] [-e3] host\n"); fprintf(stderr, "usage: showmount [-a | -d] [-e3] [host]\n");
exit(1); exit(1);
} }

View File

@ -233,7 +233,7 @@ static void
usage(void) usage(void)
{ {
fprintf(stderr, fprintf(stderr,
"usage: time [-al] [-h|-p] [-o file] utility [argument ...]\n"); "usage: time [-al] [-h | -p] [-o file] utility [argument ...]\n");
exit(1); exit(1);
} }

View File

@ -204,7 +204,7 @@ static void
usage(void) usage(void)
{ {
fprintf(stderr, "%s\n%s\n", fprintf(stderr, "%s\n%s\n",
"usage: truncate [-c] -s [+|-]size[K|M|G] file ...", "usage: truncate [-c] -s [+|-]size[K|k|M|m|G|g] file ...",
" truncate [-c] -r rfile file ..."); " truncate [-c] -r rfile file ...");
exit(EXIT_FAILURE); exit(EXIT_FAILURE);
} }

View File

@ -42,7 +42,7 @@
.Nm .Nm
.Op Fl i .Op Fl i
.Op Fl t Ar terminal .Op Fl t Ar terminal
.Op Ar name Ar ... .Op Ar
.Sh DESCRIPTION .Sh DESCRIPTION
The The
.Nm .Nm

View File

@ -165,7 +165,7 @@ main(int argc, char **argv)
static void static void
usage(void) usage(void)
{ {
fprintf(stderr, "usage: ul [-i] [-t terminal] file...\n"); fprintf(stderr, "usage: ul [-i] [-t terminal] [file ...]\n");
exit(1); exit(1);
} }

View File

@ -41,7 +41,7 @@
.Nd remove preprocessor conditionals from code .Nd remove preprocessor conditionals from code
.Sh SYNOPSIS .Sh SYNOPSIS
.Nm .Nm
.Op Fl ceklnst .Op Fl cdeklnst
.Op Fl I Ns Ar path .Op Fl I Ns Ar path
.Op Fl D Ns Ar sym Ns Op = Ns Ar val .Op Fl D Ns Ar sym Ns Op = Ns Ar val
.Op Fl U Ns Ar sym .Op Fl U Ns Ar sym
@ -153,6 +153,9 @@ is complemented,
i.e., the lines that would have been removed or blanked i.e., the lines that would have been removed or blanked
are retained and vice versa. are retained and vice versa.
.Pp .Pp
.It Fl d
Turn on printing of degugging messages.
.Pp
.It Fl e .It Fl e
Because Because
.Nm .Nm

View File

@ -300,7 +300,7 @@ main(int argc, char *argv[])
static void static void
usage(void) usage(void)
{ {
fprintf(stderr, "usage: unifdef [-cdeklnst]" fprintf(stderr, "usage: unifdef [-cdeklnst] [-Ipath]"
" [-Dsym[=val]] [-Usym] [-iDsym[=val]] [-iUsym] ... [file]\n"); " [-Dsym[=val]] [-Usym] [-iDsym[=val]] [-iUsym] ... [file]\n");
exit(2); exit(2);
} }

View File

@ -1033,7 +1033,7 @@ static void
usage(void) usage(void)
{ {
(void)fprintf(stderr, "%s%s", (void)fprintf(stderr, "%s%s",
"usage: vmstat [-aimsz] [-c count] [-M core [-N system]] [-w wait]\n", "usage: vmstat [-afimsz] [-c count] [-M core [-N system]] [-w wait]\n",
" [-n devs] [disks]\n"); " [-n devs] [-p type,if,pass] [disks]\n");
exit(1); exit(1);
} }

View File

@ -44,7 +44,7 @@
.Sh SYNOPSIS .Sh SYNOPSIS
.Nm .Nm
.Ar user .Ar user
.Op Ar ttyname .Op Ar tty
.Sh DESCRIPTION .Sh DESCRIPTION
The The
.Nm .Nm

View File

@ -57,7 +57,7 @@
.Fl n Ar number .Fl n Ar number
.Op Fl x .Op Fl x
.Oc .Oc
.Op Fl P Ar maxjobs .Op Fl P Ar maxprocs
.Op Fl s Ar size .Op Fl s Ar size
.Op Ar utility Op Ar argument ... .Op Ar utility Op Ar argument ...
.Sh DESCRIPTION .Sh DESCRIPTION

View File

@ -40,10 +40,9 @@
.Nd "extract strings from C programs to implement shared strings" .Nd "extract strings from C programs to implement shared strings"
.Sh SYNOPSIS .Sh SYNOPSIS
.Nm .Nm
.Op Fl c .Op Fl cv
.Op Fl .Op Fl
.Op Fl v .Op Ar
.Op Ar file
.Sh DESCRIPTION .Sh DESCRIPTION
The The
.Nm .Nm

View File

@ -67,7 +67,7 @@ static void
usage(void) usage(void)
{ {
fprintf(stderr, "%s\n%s\n", fprintf(stderr, "%s\n%s\n",
"usage: ypcat [-k] [-d domainname] [-t] mapname", "usage: ypcat [-kt] [-d domainname] mapname",
" ypcat -x"); " ypcat -x");
exit(1); exit(1);
} }

View File

@ -65,7 +65,7 @@ static void
usage(void) usage(void)
{ {
fprintf(stderr, "%s\n%s\n", fprintf(stderr, "%s\n%s\n",
"usage: ypmatch [-d domain] [-t] [-k] key [key ...] mname", "usage: ypmatch [-kt] [-d domainname] key ... mapname",
" ypmatch -x"); " ypmatch -x");
exit(1); exit(1);
} }