From 14aeb7ce7fd7421e9b7c28e2c8b1babdf6bdd0a8 Mon Sep 17 00:00:00 2001 From: Yu Watanabe Date: Wed, 10 Jan 2018 22:39:04 +0900 Subject: [PATCH] bash-completion: resolve: add missing options --- shell-completion/bash/systemd-resolve | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/shell-completion/bash/systemd-resolve b/shell-completion/bash/systemd-resolve index 3f789e8..ecd1eba 100644 --- a/shell-completion/bash/systemd-resolve +++ b/shell-completion/bash/systemd-resolve @@ -36,11 +36,13 @@ _systemd-resolve() { local i comps local cur=${COMP_WORDS[COMP_CWORD]} prev=${COMP_WORDS[COMP_CWORD-1]} local -A OPTS=( - [STANDALONE]='-h --help --version -4 -6 + [STANDALONE]='-h --help --version --no-pager -4 -6 --service --openpgp --tlsa --status --statistics --reset-statistics --service-address=no --service-txt=no - --cname=no --search=no --legend=no' - [ARG]='-i --interface -p --protocol -t --type -c --class' + --cname=no --search=no --legend=no --flush-caches + --reset-server-features --revert' + [ARG]='-i --interface -p --protocol -t --type -c --class --raw + --set-dns --set-domain --set-llmnr --set-mdns --set-dnssec --set-nta' ) if __contains_word "$prev" ${OPTS[ARG]}; then @@ -51,6 +53,18 @@ _systemd-resolve() { --protocol|-p|--type|-t|--class|-c) comps=$( systemd-resolve --legend=no "$prev" help; echo help ) ;; + --raw) + comps="payload packet" + ;; + --set-dns|--set-domain|--set-nta) + comps="" + ;; + --set-llmnr|--set-mdns) + comps="yes no resolve" + ;; + --set-dnssec) + comps="yes no allow-downgrade" + ;; esac COMPREPLY=( $(compgen -W '$comps' -- "$cur") ) return 0 -- 2.7.4