• E
    virsh: allow alias to expand to opt=value pair · 2b172a8e
    Eric Blake 提交于
    We want to treat 'attach-disk --shareable' as an undocumented
    alias for 'attach-disk --mode=shareable'.  By improving our
    alias handling, we can allow all such --bool -> --opt=value
    replacements, and guarantee up front that the alias is not
    mixed with its replacement.
    
    * tools/virsh.c (vshCmddefOptParse, vshCmddefGetOption): Add
    support for expanding bool alias to --opt=value.
    (opts_echo): Add another alias to test it.
    * tests/virshtest.c (mymain): Test it.
    Signed-off-by: NEric Blake <eblake@redhat.com>
    2b172a8e
virsh.c 86.7 KB