static void __attribute__((__noreturn__)) usage (FILE *fp)
{
fprintf (fp,
- _("Usage: %s [ -s shell ] [ --list-shells ] "
- "[ --help ] [ --version ]\n"
- " [ username ]\n"), whoami);
+ _("Usage: %1$s [-s shell] [username]\n"
+ " or: %1$s (--list-shells | --help | --version)\n"),
+ whoami);
exit(fp == stderr ? EXIT_FAILURE : EXIT_SUCCESS);
}
if (forked)
_exit(1);
if (strlen(strerror(errno)) > 1000)
- (void) sprintf(errbuf, _("%s: BAD ERROR"), device);
+ (void) sprintf(errbuf, _("%s: BAD ERROR, message is "
+ "far too long"), device);
else {
errsv = errno;
(void) sprintf(errbuf, "%s: %s", device,
if (rc) {
mnt_free_table(tb);
- warn(_("can't read: %s"), path);
+ warn(_("can't read %s"), path);
return NULL;
}
return tb;
fprintf(out, _(
"\nUsage:\n"
- " %s [-a|-d|-s] [--nr <N:M> | <device>] <wholedisk>\n"),
+ " %s [-a|-d|-s] [--nr <N:M> | <partition>] <disk>\n"),
program_invocation_short_name);
fprintf(out, _(
" -g, --noheadings don't print headings for --show\n"
" -r, --raw use raw format output\n"
" -t, --type <TYPE> specify the partition type (dos, bsd, solaris, etc.)\n"
- " -n, --nr <M:N> specify the range of partitions (--nr 2:4)\n"
- " -o, --output <LIST> output column\n"
+ " -n, --nr <M:N> specify the range of partitions (e.g. --nr 2:4)\n"
+ " -o, --output <LIST> define which output columns to use\n"
" -h, --help print this help\n\n"));
fprintf(out, _("\nAvailable columns (for --show):\n"));
case 'L':
case 'U':
if (source)
- errx(EX_USAGE, _("only one <source> could be specified"));
+ errx(EX_USAGE, _("only one <source> may be specified"));
if (asprintf(&srcbuf, "%s=\"%s\"",
c == 'L' ? "LABEL" : "UUID", optarg) <= 0)
err(EX_SYSERR, _("failed to allocate source buffer"));
static void __attribute__((__noreturn__)) usage(FILE *out)
{
- fprintf(out, _("Usage: %s [option]\n"),
- program_invocation_short_name);
-
- fprintf(out,_("CPU architecture information helper\n\n"
- " -h, --help usage information\n"
- " -p, --parse print out in parsable instead of printable format.\n"
- " -s, --sysroot use the directory as a new system root.\n"
- " -x, --hex print haxadecimal masks rather than lists of CPU(s)\n"));
+ fprintf(out, _(
+ "\nUsage:\n"
+ " %s [options]\n"), program_invocation_short_name);
+
+ puts(_( "\nOptions:\n"
+ " -h, --help print this help\n"
+ " -p, --parse print out a parsable instead of a readable format\n"
+ " -s, --sysroot DIR use directory DIR as system root\n"
+ " -x, --hex print hexadecimal masks rather than lists of CPUs\n"));
exit(out == stderr ? EXIT_FAILURE : EXIT_SUCCESS);
}