rice/scripts/launch.sh

24 lines
758 B
Bash
Raw Normal View History

2021-12-06 15:40:50 -08:00
#!/usr/bin/env bash
2021-07-28 23:44:53 -07:00
## Add this to your wm startup file.
# Terminate already running bar instances
killall -q polybar
# Wait until the processes have been shut down
2022-03-01 00:20:28 -08:00
while pgrep -u "$UID" -x polybar > /dev/null; do sleep 1; done
2021-07-28 23:44:53 -07:00
2021-07-28 23:54:53 -07:00
# polybar -c ~/i3/configs/config.ini main &
2021-11-14 23:54:19 -08:00
# polybar -c ~/SudacodeRice/polybar/config.ini main &
# polybar -c ~/SudacodeRice/polybar/config.ini main &
if type "xrandr"; then
2022-03-01 00:20:28 -08:00
for m in $(xrandr --query | grep -E " connected" | cut -d" " -f1); do
# MONITOR=$m polybar --reload -c ~/SudacodeRice/polybar/config.desktop.ini main &
# update to use new theme
MONITOR=$m polybar --reload -c "$HOME/SudacodeRice/polybar-themes/sblocks/config-4k.ini" main &
done
2021-11-14 23:54:19 -08:00
else
2022-03-01 00:20:28 -08:00
polybar --reload example &
2021-11-14 23:54:19 -08:00
fi