diff options
author | 2015-09-17 18:12:00 +0200 | |
---|---|---|
committer | 2015-09-17 18:12:00 +0200 | |
commit | a79c7495c83694e3de893f9bff517b9c34f2b58c (patch) | |
tree | cba5071222094d6a93c04c10b393bdcf474d5717 /share/completions/busctl.fish | |
parent | b13ee9da2aff4fa104185e0050697204d4fa6742 (diff) |
busctl completions: Fix usermode
Block-scope strikes again!
Diffstat (limited to 'share/completions/busctl.fish')
-rw-r--r-- | share/completions/busctl.fish | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/share/completions/busctl.fish b/share/completions/busctl.fish index 10b0a248..ebbba06f 100644 --- a/share/completions/busctl.fish +++ b/share/completions/busctl.fish @@ -8,10 +8,11 @@ # To speed this up, we'd need to either keep state or just assume e.g. the first non-option argument to "call" is a busname function __fish_busctl_busnames + set -l mode if __fish_contains_opt user - set -l mode "--user" + set mode "--user" else - set -l mode "--system" + set mode "--system" end command busctl $mode list --no-legend --no-pager ^/dev/null | while read a b; echo $a; end end @@ -75,20 +76,22 @@ function __fish_busctl_has_signature end function __fish_busctl_objects + set -l mode if __fish_contains_opt user - set -l mode "--user" + set mode "--user" else - set -l mode "--system" + set mode "--system" end set -l busname (__fish_busctl_has_busname) command busctl $mode tree --list --no-legend --no-pager $busname ^/dev/null | while read a b; echo $a; end end function __fish_busctl_interfaces + set -l mode if __fish_contains_opt user - set -l mode "--user" + set mode "--user" else - set -l mode "--system" + set mode "--system" end set -l busname (__fish_busctl_has_busname) set -l object (__fish_busctl_has_object) @@ -96,10 +99,11 @@ function __fish_busctl_interfaces end function __fish_busctl_members + set -l mode if __fish_contains_opt user - set -l mode "--user" + set mode "--user" else - set -l mode "--system" + set mode "--system" end set -l busname (__fish_busctl_has_busname) set -l object (__fish_busctl_has_object) @@ -120,10 +124,11 @@ function __fish_busctl_signals end function __fish_busctl_signature + set -l mode if __fish_contains_opt user - set -l mode "--user" + set mode "--user" else - set -l mode "--system" + set mode "--system" end set -l busname (__fish_busctl_has_busname) set -l object (__fish_busctl_has_object) |