2018-12-11 11:02:29 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
# Terminate already running bar instances
|
|
|
|
killall -q polybar
|
|
|
|
|
|
|
|
# Wait until the processes have been shut down
|
|
|
|
while pgrep -u $UID -x polybar >/dev/null; do sleep 1; done
|
|
|
|
|
|
|
|
# Launch bar1 and bar2
|
2019-03-08 14:43:51 +00:00
|
|
|
#polybar top &
|
|
|
|
|
2019-03-22 19:35:45 +00:00
|
|
|
if [[ "$(hostname)" == "andy-pc" ]]; then
|
|
|
|
for m in $(polybar --list-monitors | cut -d":" -f1); do
|
|
|
|
MONITOR=$m IFACE="eno1" polybar --reload top &
|
|
|
|
done
|
|
|
|
else
|
|
|
|
for m in $(polybar --list-monitors | cut -d":" -f1); do
|
2020-10-20 12:48:08 +01:00
|
|
|
MONITOR=$m IFACE="wlp1s0" polybar --reload top &
|
2019-03-22 19:35:45 +00:00
|
|
|
done
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
2018-12-11 11:02:29 +00:00
|
|
|
|
|
|
|
echo "Bars launched..."
|