voidrice/.local/bin/launch_polybar
2020-04-02 02:47:40 -04:00

14 lines
328 B
Bash
Executable File

#!/bin/sh
# Terminate already running bar instances
#killall -q polybar
# Wait until the processes have been shut down
while pgrep -x polybar >/dev/null; do killall -q polybar; done
for m in $(xrandr --query | grep " connected" | cut -d" " -f1); do
MONITOR=$m polybar --reload main &
done
notify-send "Polybar launched"