cli: fix bash completion to show general options
This fixes an error in the following example: $ nmcli con add type bridge con-name test-bridge <TAB> Before, general options such as 'autoconnect' and 'ifname' were wrongly not suggested. Signed-off-by: Thomas Haller <thaller@redhat.com>
This commit is contained in:
@@ -732,9 +732,9 @@ _nmcli()
|
||||
# means, we are at the end of options. Nothing more to parse, just show
|
||||
# what are the options now.
|
||||
if [[ "${#OPTIONS_MANDATORY[@]}" -gt 0 ]]; then
|
||||
_nmcli_list "$(echo "${OPTIONS_TYPED[@]}")"
|
||||
_nmcli_list "$(echo "${OPTIONS[@]}")"
|
||||
else
|
||||
_nmcli_list "$(echo "${OPTIONS_TYPED[@]}") $(echo "${OPTIONS_IP[@]}")"
|
||||
_nmcli_list "$(echo "${OPTIONS[@]}") $(echo "${OPTIONS_IP[@]}")"
|
||||
fi
|
||||
return 0
|
||||
fi
|
||||
|
Reference in New Issue
Block a user