sxhkd: Add ability to dynamically adjust gaps/borders

This lets us use bspwm and occasionally make it look completely
different without having to worry about manually typing things out in a
terminal.
This commit is contained in:
Donovan Glover 2022-11-03 11:45:00 -04:00
parent d41321b427
commit ba0ad5b142
No known key found for this signature in database
GPG Key ID: EA7408A77AE1BE65

View File

@ -5,6 +5,18 @@
super + {_, alt} + Escape
{pkill -USR1 -x sxhkd && notify-send -t 2000 "sxhkd" "Reloaded config",bspc quit}
# Dynamically adjust gaps of current desktop
super + {_, shift +} g
{ bspc config -d focused window_gap $(( $(bspc config -d focused window_gap) + 20 )), \
[ $(bspc config -d focused window_gap) -ge 20 ] && \
bspc config -d focused window_gap $(( $(bspc config -d focused window_gap) - 20 )) }
# Dynamically adjust borders of nodes on current desktop
super + {_, shift +} i
{ bspc config -d focused border_width $(( $(bspc config -d focused border_width) + 1 )), \
[ $(bspc config -d focused border_width) -ge 1 ] && \
bspc config -d focused border_width $(( $(bspc config -d focused border_width) - 1 )) }
# Take a screenshot
super + p
~/.config/sxhkd/screenshot.sh