]> git.ipfire.org Git - thirdparty/systemd.git/blob - shell-completion/zsh/_sd_machines
pkgconfig: define variables relative to ${prefix}/${rootprefix}/${sysconfdir}
[thirdparty/systemd.git] / shell-completion / zsh / _sd_machines
1 #autoload
2 # SPDX-License-Identifier: LGPL-2.1+
3 __get_machines () {
4 machinectl --full --no-legend --no-pager list | {while read -r a b; do echo $a; done;};
5 }
6
7 local -a _machines
8 _machines=("${(fo)$(__get_machines)}")
9 typeset -U _machines
10 if [[ -n "$_machines" ]]; then
11 _describe 'machines' _machines
12 else
13 _message 'no machines'
14 fi