dots/.scripts/bar/toggle

22 lines
320 B
Plaintext
Raw Normal View History

2021-08-20 21:22:37 +02:00
#!/usr/bin/env bash
2021-08-21 18:57:24 +02:00
visible=$CONFIG/polybar/.visible
2021-08-20 21:22:37 +02:00
barheight=27
2021-08-21 18:57:24 +02:00
padding=0
2021-08-20 21:22:37 +02:00
if [ -f $visible ]; then
polybar-msg cmd hide
rm $visible
else
2021-08-21 18:57:24 +02:00
#bspc config top_padding ((padding+$barheight))
2021-08-20 21:22:37 +02:00
polybar-msg cmd show
2021-08-21 18:57:24 +02:00
((padding=padding+barheight))
2021-08-20 21:22:37 +02:00
touch $visible
fi
2021-08-21 18:57:24 +02:00
bspc config top_padding $padding
2021-08-20 21:22:37 +02:00