diff options
author | Daniel Mack <github@zonque.org> | 2015-06-02 17:43:29 +0200 |
---|---|---|
committer | Daniel Mack <github@zonque.org> | 2015-06-02 17:43:29 +0200 |
commit | ad2274289b36961c6c397f9d22dff55185b13c18 (patch) | |
tree | aa6aec15a00813fd5766ca133d66577c7f2eb38f /shell-completion/zsh/_systemctl.in | |
parent | ea3db0141889301964c6214e1d2423d32d570946 (diff) | |
parent | 68c4f6d406a2bdac6957a67a077f182b0287cc3b (diff) |
Merge pull request #4 from systemd-mailing-devs/1431989131-25145-1-git-send-email-llua@gmx.com
zsh-completion: fix completion of --user services
Diffstat (limited to 'shell-completion/zsh/_systemctl.in')
-rw-r--r-- | shell-completion/zsh/_systemctl.in | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/shell-completion/zsh/_systemctl.in b/shell-completion/zsh/_systemctl.in index 1dc6406beb..db9bdb60c5 100644 --- a/shell-completion/zsh/_systemctl.in +++ b/shell-completion/zsh/_systemctl.in @@ -93,9 +93,7 @@ __systemctl() { - local -a _modes - _modes=("--user" "--system") - systemctl ${words:*_modes} --full --no-legend --no-pager "$@" + systemctl $_sys_service_mgr --full --no-legend --no-pager "$@" } @@ -355,6 +353,8 @@ _job_modes() { _values -s , "${_modes[@]}" } +local -a _modes; _modes=("--user" "--system") +local _sys_service_mgr=${${words:*_modes}[(R)(${(j.|.)_modes})]:---system} _arguments -s \ {-h,--help}'[Show help]' \ '--version[Show package version]' \ |