From: Benno Schulenberg <bensberg@justemail.net>
To: util-linux@vger.kernel.org
Subject: [PATCH 2/8] textual: do not start option descriptions with a capital
Date: Sun, 14 Dec 2014 20:45:27 +0100 [thread overview]
Message-ID: <1418586333-5342-2-git-send-email-bensberg@justemail.net> (raw)
In-Reply-To: <1418586333-5342-1-git-send-email-bensberg@justemail.net>
This normalizes the help text of getopt, clarifies one description,
and also adjust two comments.
Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
---
misc-utils/getopt.c | 28 ++++++++++++++--------------
1 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/misc-utils/getopt.c b/misc-utils/getopt.c
index 197bae7..85cac32 100644
--- a/misc-utils/getopt.c
+++ b/misc-utils/getopt.c
@@ -91,12 +91,12 @@ struct getopt_control {
enum { REALLOC_INCREMENT = 8 };
-/* Allow changing which getopt is in use with function pointer */
+/* Allow changing which getopt is in use with function pointer. */
int (*getopt_long_fp) (int argc, char *const *argv, const char *optstr,
const struct option * longopts, int *longindex);
/*
- * This function 'print_normalizeds' a single argument: it puts single quotes
+ * This function 'normalizes' a single argument: it puts single quotes
* around it and escapes other special characters. If quote is false, it
* just returns its argument.
*
@@ -314,21 +314,21 @@ static void __attribute__ ((__noreturn__)) print_help(void)
{
fputs(USAGE_HEADER, stderr);
fprintf(stderr, _(
- " %1$s optstring parameters\n"
- " %1$s [options] [--] optstring parameters\n"
- " %1$s [options] -o|--options optstring [options] [--] parameters\n"),
+ " %1$s <optstring> <parameters>\n"
+ " %1$s [options] [--] <optstring> <parameters>\n"
+ " %1$s [options] -o|--options <optstring> [options] [--] <parameters>\n"),
program_invocation_short_name);
fputs(USAGE_OPTIONS, stderr);
- fputs(_(" -a, --alternative Allow long options starting with single -\n"), stderr);
- fputs(_(" -l, --longoptions <longopts> Long options to be recognized\n"), stderr);
- fputs(_(" -n, --name <progname> The name under which errors are reported\n"), stderr);
- fputs(_(" -o, --options <optstring> Short options to be recognized\n"), stderr);
- fputs(_(" -q, --quiet Disable error reporting by getopt(3)\n"), stderr);
- fputs(_(" -Q, --quiet-output No normal output\n"), stderr);
- fputs(_(" -s, --shell <shell> Set shell quoting conventions\n"), stderr);
- fputs(_(" -T, --test Test for getopt(1) version\n"), stderr);
- fputs(_(" -u, --unquoted Do not quote the output\n"), stderr);
+ fputs(_(" -a, --alternative allow long options starting with single -\n"), stderr);
+ fputs(_(" -l, --longoptions <longopts> the long options to be recognized\n"), stderr);
+ fputs(_(" -n, --name <progname> the name under which errors are reported\n"), stderr);
+ fputs(_(" -o, --options <optstring> the short options to be recognized\n"), stderr);
+ fputs(_(" -q, --quiet disable error reporting by getopt(3)\n"), stderr);
+ fputs(_(" -Q, --quiet-output no normal output\n"), stderr);
+ fputs(_(" -s, --shell <shell> set quoting conventions to those of <shell>\n"), stderr);
+ fputs(_(" -T, --test test for getopt(1) version\n"), stderr);
+ fputs(_(" -u, --unquoted do not quote the output\n"), stderr);
fputs(USAGE_SEPARATOR, stderr);
fputs(USAGE_HELP, stderr);
fputs(USAGE_VERSION, stderr);
--
1.7.0.4
next prev parent reply other threads:[~2014-12-14 19:45 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-14 19:45 [PATCH 1/8] docs: fix the grammar of the recent comment about comments Benno Schulenberg
2014-12-14 19:45 ` Benno Schulenberg [this message]
2014-12-14 19:45 ` [PATCH 3/8] docs: improve the sorting of the options in the man page of getopt Benno Schulenberg
2014-12-14 19:45 ` [PATCH 4/8] docs: don't use bold or italics for "[option]" in synopsis of man pages Benno Schulenberg
2014-12-14 19:45 ` [PATCH 5/8] docs: adjust the grammar, text, sorting and formatting of logger man page Benno Schulenberg
2014-12-14 19:50 ` Benno Schulenberg
2014-12-15 19:03 ` Sami Kerola
2014-12-14 19:45 ` [PATCH 6/8] docs: adjust some formatting and wordings in a handful of man pages Benno Schulenberg
2014-12-14 19:45 ` [PATCH 7/8] docs: fix the grammar and formatting in the man page of sfdisk Benno Schulenberg
2014-12-14 19:45 ` [PATCH 8/8] sfdisk: in the usage text show -v for --version instead of -V Benno Schulenberg
2014-12-19 9:01 ` [PATCH 1/8] docs: fix the grammar of the recent comment about comments Karel Zak
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1418586333-5342-2-git-send-email-bensberg@justemail.net \
--to=bensberg@justemail.net \
--cc=util-linux@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).