]> git.ipfire.org Git - thirdparty/libvirt.git/commit
vsh: Allow one optional positional argument
authorPeter Krempa <pkrempa@redhat.com>
Thu, 14 Mar 2024 15:21:58 +0000 (16:21 +0100)
committerPeter Krempa <pkrempa@redhat.com>
Tue, 2 Apr 2024 12:24:29 +0000 (14:24 +0200)
commitfc7934695d24ced6b7b5de5042b88bb001ab9eb8
tree50c698b98a9170f8ec2ddc76842dea86e53bf9a1
parent627cf466f09300fc7d863a09118a5e865b5c9fb1
vsh: Allow one optional positional argument

We already allow a optional positional _ARGV argument but there's no
reason why any other argument type could not be allowed this way.

Add checks that there's just one such argument and it's placed after
required positional arguments.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
tools/vsh.c