From 4c5a6f3d3927c83a782e4e567fee0b6d66813dc4 Mon Sep 17 00:00:00 2001 From: Benno Schulenberg Date: Sun, 9 Feb 2014 11:26:49 +0100 Subject: more: improve formatting and wording of man page and help text Also, slice up the usage text for ease of translation. Reported-by: Phillip Susi Signed-off-by: Benno Schulenberg --- text-utils/more.c | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) (limited to 'text-utils/more.c') diff --git a/text-utils/more.c b/text-utils/more.c index 4c39887e9..b06abbb63 100644 --- a/text-utils/more.c +++ b/text-utils/more.c @@ -315,22 +315,21 @@ static char *my_tgoto(char *cap, int col, int row) static void __attribute__((__noreturn__)) usage(FILE *out) { - fprintf(out, - _("Usage: %s [options] file...\n\n"), - program_invocation_short_name); - fprintf(out, - _("Options:\n" - " -d display help instead of ring bell\n" - " -f count logical, rather than screen lines\n" - " -l suppress pause after form feed\n" - " -p do not scroll, clean screen and display text\n" - " -c do not scroll, display text and clean line ends\n" - " -u suppress underlining\n" - " -s squeeze multiple blank lines into one\n" - " -NUM specify the number of lines per screenful\n" - " +NUM display file beginning from line number NUM\n" - " +/STRING display file beginning from search string match\n" - " -V output version information and exit\n")); + fputs(USAGE_HEADER, out); + fprintf(out, _(" %s [options] ...\n"), program_invocation_short_name); + fputs(USAGE_OPTIONS, out); + fputs(_(" -d display help instead of ringing bell\n"), out); + fputs(_(" -f count logical rather than screen lines\n"), out); + fputs(_(" -l suppress pause after form feed\n"), out); + fputs(_(" -c do not scroll, display text and clean line ends\n"), out); + fputs(_(" -p do not scroll, clean screen and display text\n"), out); + fputs(_(" -s squeeze multiple blank lines into one\n"), out); + fputs(_(" -u suppress underlining\n"), out); + fputs(_(" - the number of lines per screenful\n"), out); + fputs(_(" + display file beginning from line number\n"), out); + fputs(_(" +/ display file beginning from search string match\n"), out); + fputs(_(" -V display version information and exit\n"), out); + fprintf(out, USAGE_MAN_TAIL("more(1)")); exit(out == stderr ? EXIT_FAILURE : EXIT_SUCCESS); } -- cgit v1.2.3-55-g7522