On Thursday, 25 August 2016 13:15:29 CEST Richard W.M. Jones wrote:
Add new scripts for:
- guestunmount
- virt-copy-in
- virt-copy-out
- virt-customize
- virt-dib
- virt-diff
- virt-get-kernel
- virt-p2v-make-disk
- virt-p2v-make-kickstart
- virt-p2v-make-kiwi
- virt-tar-in
- virt-tar-out
Also combine the separate virt-resize script into the general script
virt-alignment-scan. There wasn't really any reason to have separate
scripts.
---
I guess ...
diff --git a/fuse/guestunmount.c b/fuse/guestunmount.c
index efd342f..fe86706 100644
--- a/fuse/guestunmount.c
+++ b/fuse/guestunmount.c
@@ -83,8 +83,10 @@ main (int argc, char *argv[])
{ "fd", 1, 0, 0 },
{ "help", 0, 0, HELP_OPTION },
{ "quiet", 0, 0, 'q' },
+ { "long-options", 0, 0, 0 },
{ "no-retry", 0, 0, 0 },
{ "retry", 1, 0, 0 },
+ { "short-options", 0, 0, 0 },
{ "verbose", 0, 0, 'v' },
{ "version", 0, 0, 'V' },
{ 0, 0, 0, 0 }
@@ -108,7 +110,11 @@ main (int argc, char *argv[])
switch (c) {
case 0: /* options which are long only */
- if (STREQ (long_options[option_index].name, "fd")) {
+ if (STREQ (long_options[option_index].name, "long-options"))
+ display_long_options (long_options);
+ else if (STREQ (long_options[option_index].name, "short-options"))
+ display_short_options (options);
+ else if (STREQ (long_options[option_index].name, "fd")) {
if (sscanf (optarg, "%d", &fd) != 1 || fd < 0)
error (EXIT_FAILURE, 0, _("cannot parse fd option '%s'"),
optarg);
} else if (STREQ (long_options[option_index].name, "no-retry")) {
... this should be part of patch #2, shouldn't it?
Thanks,
--
Pino Toscano