bspwm/contrib/zsh_completion

24 lines
1,022 B
Text
Raw Normal View History

2013-08-16 11:59:09 +02:00
#compdef bspc
_bspc() {
2014-01-21 20:51:02 +01:00
local -a commands settings
2016-04-07 18:08:32 +02:00
commands=('node' 'desktop' 'monitor' 'query' 'rule' 'restore' 'wm' 'subscribe' 'config' 'quit')
settings=('external_rules_command' 'status_prefix' 'normal_border_color' 'active_border_color' 'focused_border_color' 'presel_feedback_color' 'border_width' 'window_gap' 'top_padding' 'right_padding' 'bottom_padding' 'left_padding' 'split_ratio' 'initial_polarity' 'borderless_monocle' 'gapless_monocle' 'single_monocle' 'pointer_modifier' 'pointer_action1' 'pointer_action2' 'pointer_action3' 'click_to_focus' 'focus_follows_pointer' 'pointer_follows_focus' 'pointer_follows_monitor' 'ignore_ewmh_focus' 'center_pseudo_tiled' 'honor_size_hints' 'remove_disabled_monitors' 'remove_unplugged_monitors' 'merge_overlapping_monitors')
2014-01-21 20:51:02 +01:00
if (( CURRENT == 2 )) ; then
_values 'command' "$commands[@]"
elif (( CURRENT == 3 )) ; then
case $words[2] in
config)
_values 'setting' "$settings[@]"
;;
*)
return 1
;;
esac
else
return 1
fi
2013-08-16 11:59:09 +02:00
}
_bspc "$@"