bash-completion: resolvectl: support 'log-level' command
This commit is contained in:
parent
bde4bc9bd2
commit
3605aae161
|
@ -48,6 +48,7 @@ _resolvectl() {
|
||||||
[DNSSEC]='dnssec'
|
[DNSSEC]='dnssec'
|
||||||
[DNSOVERTLS]='dnsovertls'
|
[DNSOVERTLS]='dnsovertls'
|
||||||
[STANDALONE]='statistics reset-statistics flush-caches reset-server-features'
|
[STANDALONE]='statistics reset-statistics flush-caches reset-server-features'
|
||||||
|
[LOG_LEVEL]='log-level'
|
||||||
)
|
)
|
||||||
local -A ARGS=(
|
local -A ARGS=(
|
||||||
[FAMILY]='tcp udp sctp'
|
[FAMILY]='tcp udp sctp'
|
||||||
|
@ -95,6 +96,9 @@ _resolvectl() {
|
||||||
elif __contains_word "$verb" ${VERBS[STATUS]}; then
|
elif __contains_word "$verb" ${VERBS[STATUS]}; then
|
||||||
comps="$interfaces"
|
comps="$interfaces"
|
||||||
|
|
||||||
|
elif __contains_word "$verb" ${VERBS[LOG_LEVEL]}; then
|
||||||
|
comps='debug info notice warning err crit alert emerg'
|
||||||
|
|
||||||
elif __contains_word "$verb" ${VERBS[FAMILY]}; then
|
elif __contains_word "$verb" ${VERBS[FAMILY]}; then
|
||||||
for ((i++; i < COMP_CWORD; i++)); do
|
for ((i++; i < COMP_CWORD; i++)); do
|
||||||
if __contains_word "${COMP_WORDS[i]}" ${ARGS[FAMILY]} &&
|
if __contains_word "${COMP_WORDS[i]}" ${ARGS[FAMILY]} &&
|
||||||
|
|
Loading…
Reference in New Issue