]> git.ipfire.org Git - thirdparty/systemd.git/commit
zsh-completion: fix completion of --user services 4/head
authorEric Cook <llua@gmx.com>
Mon, 18 May 2015 22:45:31 +0000 (18:45 -0400)
committerHarald Hoyer <harald@redhat.com>
Mon, 18 May 2015 23:01:40 +0000 (01:01 +0200)
commit68c4f6d406a2bdac6957a67a077f182b0287cc3b
treeb95dda4942c28c73183b2a2a96616080459d50b9
parent9530e0d023b0e9308f19eadf6e42cdc25bc30793
zsh-completion: fix completion of --user services

By the time __systemctl is called, --user/--system are shifted out of
`words' by _arguments. This patch queries the array sooner.

In the case that both --user and --system are on the line when compsys runs,
_sys_service_mgr is set to the latter. Which is seemingly how systemctl behaves.

If neither are on the line, --system is set; for system services to be completed.
shell-completion/zsh/_systemctl.in