diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2015-09-28 14:43:26 -0400 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2015-09-28 15:10:03 -0400 |
commit | 840b2c0e77911bef3056f358b8d16a3253e4ab70 (patch) | |
tree | b6f8adccec9b56b30f694db3122a122b76d9dde1 /shell-completion/zsh/_systemctl.in | |
parent | 7e55de3b9648a47286a9b49253f95b1e0d65287a (diff) |
shell-completion: use systemctl --state=help
This way completion lists should stay up to date.
Also use systemctl -t help to list types in zsh, as was already
done in bash.
Diffstat (limited to 'shell-completion/zsh/_systemctl.in')
-rw-r--r-- | shell-completion/zsh/_systemctl.in | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/shell-completion/zsh/_systemctl.in b/shell-completion/zsh/_systemctl.in index 4bf306aacb..96f51a0ee0 100644 --- a/shell-completion/zsh/_systemctl.in +++ b/shell-completion/zsh/_systemctl.in @@ -334,13 +334,13 @@ _systemctl_caching_policy() _unit_states() { local -a _states - _states=(loaded failed active inactive not-found listening running waiting plugged mounted exited dead masked) + _states=("${(fo)$(__systemctl --state=help)}") _values -s , "${_states[@]}" } _unit_types() { local -a _types - _types=(automount busname device mount path service snapshot socket swap target timer) + _types=("${(fo)$(__systemctl -t help)}") _values -s , "${_types[@]}" } |