8cd095cc2724dac7523eda400522bbda41219d43Zbigniew Jędrzejewski-Szmek# busctl(1) completion -*- shell-script -*-
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# This file is part of systemd.
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# Copyright 2013 Zbigniew Jędrzejewski-Szmek
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# systemd is free software; you can redistribute it and/or modify it
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# under the terms of the GNU Lesser General Public License as published by
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# the Free Software Foundation; either version 2.1 of the License, or
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# (at your option) any later version.
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# systemd is distributed in the hope that it will be useful, but
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# WITHOUT ANY WARRANTY; without even the implied warranty of
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# General Public License for more details.
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# You should have received a copy of the GNU Lesser General Public License
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek# along with systemd; If not, see <http://www.gnu.org/licenses/>.
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek(( $+functions[_busctl_command] )) || _busctl_command()
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek local -a _busctl_cmds
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek "list:List bus names"
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu "status:Show bus service, process or bus owner credentials"
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek "monitor:Show bus traffic"
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu "capture:Capture bus traffix as pcap"
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu "tree:Show object tree of service"
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu "introspect:Introspect object"
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu "call:Call a method"
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu "get-property:Get property value"
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu "set-property:Set property value"
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek if (( CURRENT == 1 )); then
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek _describe -t commands 'busctl command' _busctl_cmds || compadd "$@"
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek local curcontext="$curcontext"
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek cmd="${${_busctl_cmds[(r)$words[1]:*]%%:*}}"
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek if (( $+functions[_busctl_$cmd] )); then
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek _message "no more options"
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek {-h,--help}'[Prints a short help text and exits.]' \
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek '--version[Prints a short version string and exits.]' \
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek '--no-pager[Do not pipe output into a pager]' \
4433c995c77b66f42fe4a238aff6b53706628a2eDaniel Mack '--no-legend[Do not show the headers and footers]' \
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek '--system[Connect to system manager]' \
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek '--user[Connect to user service manager]' \
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek {-H+,--host=}'[Operate on remote host]:userathost:_sd_hosts_or_user_at_host' \
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek {-M+,--machine=}'[Operate on local container]:machines:_sd_machines' \
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek '--address=[Connect to the bus specified by address]:address' \
4433c995c77b66f42fe4a238aff6b53706628a2eDaniel Mack '--show-machine[Show machine ID column in list]' \
4433c995c77b66f42fe4a238aff6b53706628a2eDaniel Mack '--unique[Only show unique names]' \
4433c995c77b66f42fe4a238aff6b53706628a2eDaniel Mack '--acquired[Only show acquired names]' \
4433c995c77b66f42fe4a238aff6b53706628a2eDaniel Mack '--activatable[Only show activatable names]' \
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek '--match=[Only show matching messages]:match' \
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu '--list[Do not show tree, but simple object path list]' \
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu '--quiet[Do not show method call reply]'\
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu '--verbose[Show result values in long format]' \
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu '--expect-reply=[Expect a method call reply]:boolean:(1 0)' \
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu '--auto-start=[Auto-start destination service]:boolean:(1 0)' \
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu '--allow-interactive-authorization=[Allow interactive authorization for operation]:boolean:(1 0)' \
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu '--timeout=[Maximum time to wait for method call completion]:timeout (seconds)' \
cade10ccefe48dba8fe506952e3ee9185593a921Nicolas Cornu '--augment-creds=[Extend credential data with data read from /proc/$PID]:boolean:(1 0)' \
86cb0691b71873c6fe30a103dc98153e2d9ab507Zbigniew Jędrzejewski-Szmek '*::busctl command:_busctl_command'