[PATCH 22/28] virsh: volume: Mark optional 'pool' argument as 'positional'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Annotate arguments which can be unintentionally parsed positionally.
(See previous commits for explanation.)

The pool name is optional but in all cases it can be promoted to an
optional positional argument so that it can be properly aligned with the
expectations of the parser.

Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx>
---
 tools/virsh-volume.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tools/virsh-volume.c b/tools/virsh-volume.c
index 8794126f21..7e6c6d5ef5 100644
--- a/tools/virsh-volume.c
+++ b/tools/virsh-volume.c
@@ -49,6 +49,7 @@
 #define VIRSH_COMMON_OPT_POOL_OPTIONAL \
     {.name = "pool", \
      .type = VSH_OT_STRING, \
+     .positional = true, \
      .help = N_("pool name or uuid"), \
      .completer = virshStoragePoolNameCompleter, \
      .completer_flags = VIR_CONNECT_LIST_STORAGE_POOLS_ACTIVE, \
-- 
2.44.0
_______________________________________________
Devel mailing list -- devel@xxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxx




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux