forgot to include this file in earlier commits

This commit is contained in:
Lucien Cartier-Tilet 2019-11-23 18:44:13 +01:00
parent 200210679e
commit ba8131a51b
Signed by: phundrak
GPG Key ID: BD7789E705CB8DCA
1 changed files with 17 additions and 0 deletions

17
.local/bin/polybar-launch Executable file
View File

@ -0,0 +1,17 @@
#!/usr/bin/env bash
killall -q polybar
while pgrep -u $UID -x polybar >/dev/null; do sleep 1; done
if type "xrandr"; then
for m in $(xrandr --query | grep " connected" | cut -d" " -f1); do
MONITOR=$m polybar --reload top &
MONITOR=$m polybar --reload bottom &
done
else
polybar --reload top &
polybar --reload bottom &
fi
notify-send "Polybar restarted!" -a "polybar-launch"