2022-12-13 23:07:33 +00:00
|
|
|
#!/usr/bin/env bash
|
2020-02-07 16:32:59 +00:00
|
|
|
|
|
|
|
# Terminate already running bar instances
|
2022-12-13 23:07:33 +00:00
|
|
|
pkill polybar
|
|
|
|
|
|
|
|
sleep 0.5
|
2020-02-07 16:32:59 +00:00
|
|
|
|
|
|
|
# Wait until the processes have been shut down
|
|
|
|
while pgrep -u $UID -x polybar >/dev/null; do sleep 1; done
|
|
|
|
|
2020-03-01 15:12:18 +00:00
|
|
|
host_name=$(cat /proc/sys/kernel/hostname)
|
2020-02-13 17:25:00 +00:00
|
|
|
if [[ $host_name == "portalo" ]]; then
|
|
|
|
polybar portalo-primary &
|
|
|
|
polybar portalo-secondary &
|
|
|
|
elif [[ $host_name == *"laptop"* ]]; then
|
|
|
|
polybar laptop-primary &
|
2021-04-07 10:39:01 +00:00
|
|
|
polybar laptop-secondary &
|
2020-02-13 17:25:00 +00:00
|
|
|
else
|
2023-01-29 00:57:35 +00:00
|
|
|
#polybar base &
|
|
|
|
polybar laptop-primary &
|
|
|
|
polybar laptop-secondary &
|
2020-02-13 17:25:00 +00:00
|
|
|
fi
|