Skip to content

Commit

Permalink
cli: autocomplete >1 service for enable/disable
Browse files Browse the repository at this point in the history
  • Loading branch information
orndorffgrant committed Nov 15, 2023
1 parent 66c51ee commit 0fb8ed8
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion tools/ua.bash
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,22 @@ _ua_complete()
esac
;;
*)
COMPREPLY=()
local subcmd
subcmd="${COMP_WORDS[1]}"
case ${subcmd} in
disable)
# shellcheck disable=SC2207
COMPREPLY=($(compgen -W "$SERVICES" -- $cur_word))
;;
enable)
# shellcheck disable=SC2207
COMPREPLY=($(compgen -W "$SERVICES" -- $cur_word))
;;
*)
COMPREPLY=()
;;

esac
;;
esac
}
Expand Down

0 comments on commit 0fb8ed8

Please sign in to comment.