diff options
author | Ruediger Meier | 2017-06-25 14:49:47 +0200 |
---|---|---|
committer | Ruediger Meier | 2017-06-27 12:28:36 +0200 |
commit | b30544549505019f5fc092c5d99fcb1cae1a44b1 (patch) | |
tree | b22fa305e99ed2bfa3bdeb145e8094874b631754 /disk-utils | |
parent | misc: introduce print_usage_help_options() (diff) | |
download | kernel-qcow2-util-linux-b30544549505019f5fc092c5d99fcb1cae1a44b1.tar.gz kernel-qcow2-util-linux-b30544549505019f5fc092c5d99fcb1cae1a44b1.tar.xz kernel-qcow2-util-linux-b30544549505019f5fc092c5d99fcb1cae1a44b1.zip |
misc: consolidate all --help option descriptions
Now we are always using the same text also for commands
which had still hardcoded descriptions or where we can't
use the standard print_usage_help_options macro.
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
Diffstat (limited to 'disk-utils')
-rw-r--r-- | disk-utils/fsck.c | 4 | ||||
-rw-r--r-- | disk-utils/fsck.cramfs.c | 4 | ||||
-rw-r--r-- | disk-utils/mkfs.bfs.c | 5 | ||||
-rw-r--r-- | disk-utils/mkfs.c | 5 | ||||
-rw-r--r-- | disk-utils/mkswap.c | 5 |
5 files changed, 10 insertions, 13 deletions
diff --git a/disk-utils/fsck.c b/disk-utils/fsck.c index 918103ac0..3fe3959c1 100644 --- a/disk-utils/fsck.c +++ b/disk-utils/fsck.c @@ -1394,8 +1394,8 @@ static void __attribute__((__noreturn__)) usage(void) fputs(_(" -V explain what is being done\n"), out); fputs(USAGE_SEPARATOR, out); - fputs(_(" -?, --help display this help and exit\n"), out); - fputs(_(" --version output version information and exit\n"), out); + printf( " -?, --help %s\n", USAGE_OPTSTR_HELP); + printf( " --version %s\n", USAGE_OPTSTR_VERSION); fputs(USAGE_SEPARATOR, out); fputs(_("See the specific fsck.* commands for available fs-options."), out); fprintf(out, USAGE_MAN_TAIL("fsck(8)")); diff --git a/disk-utils/fsck.cramfs.c b/disk-utils/fsck.cramfs.c index 9fade86d2..465685278 100644 --- a/disk-utils/fsck.cramfs.c +++ b/disk-utils/fsck.cramfs.c @@ -120,9 +120,9 @@ static void __attribute__((__noreturn__)) usage(void) fputs(_(" -b, --blocksize <size> use this blocksize, defaults to page size\n"), out); fputs(_(" --extract[=<dir>] test uncompression, optionally extract into <dir>\n"), out); fputs(USAGE_SEPARATOR, out); - print_usage_help_options(16); - fputs(USAGE_SEPARATOR, out); + print_usage_help_options(26); + printf(USAGE_MAN_TAIL("fsck.cramfs(8)")); exit(FSCK_EX_OK); } diff --git a/disk-utils/mkfs.bfs.c b/disk-utils/mkfs.bfs.c index b19afa7cd..fbf2887ca 100644 --- a/disk-utils/mkfs.bfs.c +++ b/disk-utils/mkfs.bfs.c @@ -84,9 +84,8 @@ static void __attribute__((__noreturn__)) usage(void) " -v, --verbose explain what is being done\n" " -c this option is silently ignored\n" " -l this option is silently ignored\n" - " -V, --version output version information and exit\n" - " -V as version must be only option\n" - " -h, --help display this help and exit\n\n")); + )); + print_usage_help_options(21); fprintf(out, USAGE_MAN_TAIL("mkfs.bfs(8)")); exit(EXIT_SUCCESS); diff --git a/disk-utils/mkfs.c b/disk-utils/mkfs.c index 25cc59d20..f7b0c0a09 100644 --- a/disk-utils/mkfs.c +++ b/disk-utils/mkfs.c @@ -55,12 +55,9 @@ static void __attribute__((__noreturn__)) usage(void) fprintf(out, _(" <size> number of blocks to be used on the device\n")); fprintf(out, _(" -V, --verbose explain what is being done;\n" " specifying -V more than once will cause a dry-run\n")); - fprintf(out, _(" -V, --version display version information and exit;\n" - " -V as --version must be the only option\n")); - fprintf(out, _(" -h, --help display this help text and exit\n")); + print_usage_help_options(20); fprintf(out, USAGE_MAN_TAIL("mkfs(8)")); - exit(EXIT_SUCCESS); } diff --git a/disk-utils/mkswap.c b/disk-utils/mkswap.c index 73e5258ed..593a61e03 100644 --- a/disk-utils/mkswap.c +++ b/disk-utils/mkswap.c @@ -160,9 +160,10 @@ static void __attribute__((__noreturn__)) usage(void) " -L, --label LABEL specify label\n" " -v, --swapversion NUM specify swap-space version number\n" " -U, --uuid UUID specify the uuid to use\n" - " -V, --version output version information and exit\n" - " -h, --help display this help and exit\n\n")); + )); + print_usage_help_options(27); + printf(USAGE_MAN_TAIL("mkswap(8)")); exit(EXIT_SUCCESS); } |