diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2014-07-21 21:11:56 -0400 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2014-07-21 22:33:51 -0400 |
commit | 2c12a402cb1e8277c271ced8dc9c06d20b8f6017 (patch) | |
tree | d753435ad96d1377820862987ab5831a0b98a46f /shell-completion/bash | |
parent | 1d3bc0177a1952473bbe45b5bbb4e4e4f69a84f4 (diff) |
shell-completion: systemd-analyze verify, systemctl link
Some zsh completion helpers were not installed, so completion
was broken.
Add systemd-analyze verify. Make systemctl link complete only
unit names.
Diffstat (limited to 'shell-completion/bash')
-rw-r--r-- | shell-completion/bash/systemctl.in | 2 | ||||
-rw-r--r-- | shell-completion/bash/systemd-analyze | 9 |
2 files changed, 10 insertions, 1 deletions
diff --git a/shell-completion/bash/systemctl.in b/shell-completion/bash/systemctl.in index 4beec4e13f..c5950cc752 100644 --- a/shell-completion/bash/systemctl.in +++ b/shell-completion/bash/systemctl.in @@ -89,7 +89,7 @@ _systemctl () { comps=$(compgen -A signal) ;; --type|-t) - comps='automount device mount path service snapshot socket swap target timer' + comps='automount busname device mount path service snapshot socket swap target timer' ;; --state) comps='loaded not-found stub diff --git a/shell-completion/bash/systemd-analyze b/shell-completion/bash/systemd-analyze index 5575bebfc4..77d1b542a2 100644 --- a/shell-completion/bash/systemd-analyze +++ b/shell-completion/bash/systemd-analyze @@ -44,6 +44,7 @@ _systemd_analyze() { [CRITICAL_CHAIN]='critical-chain' [DOT]='dot' [LOG_LEVEL]='set-log-level' + [VERIFY]='verify' ) _init_completion || return @@ -99,6 +100,14 @@ _systemd_analyze() { comps='debug info notice warning err crit alert emerg' fi + elif __contains_word "$verb" ${VERBS[VERIFY]}; then + if [[ $cur = -* ]]; then + comps='--help --version --system --user --no-man' + else + comps=$( compgen -A file -- "$cur" ) + compopt -o filenames + fi + fi COMPREPLY=( $(compgen -W '$comps' -- "$cur") ) |