diff options
author | David Luevano Alvarado <55825613+luevano@users.noreply.github.com> | 2020-12-20 13:11:43 -0700 |
---|---|---|
committer | David Luevano Alvarado <55825613+luevano@users.noreply.github.com> | 2020-12-20 13:11:43 -0700 |
commit | 274c4c187f199d1c9dc59793f99e50d2d50f01a9 (patch) | |
tree | a6abee5829cb407158575af63a7110e780e378dd /.local/bin/statusbar/polybar_panel | |
parent | b0a8649d522ca19ed9a85090a915a0709b916e85 (diff) |
Add polybar and rename lemonbar
Diffstat (limited to '.local/bin/statusbar/polybar_panel')
-rwxr-xr-x | .local/bin/statusbar/polybar_panel | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/.local/bin/statusbar/polybar_panel b/.local/bin/statusbar/polybar_panel new file mode 100755 index 0000000..d3e198c --- /dev/null +++ b/.local/bin/statusbar/polybar_panel @@ -0,0 +1,21 @@ +#!/bin/sh + +# Terminate already running bar instances +killall -q polybar + +# Wait until the processes have been shut down +while pgrep -u "$(id -ru)" -x polybar >/dev/null; do sleep 1; done + +# Launch bar1 and bar2 +bar1=main +bar2=second +echo "---" | tee -a /tmp/$bar1.log /tmp/$bar2.log + +polybar $bar1 >>/tmp/$bar1.log 2>&1 & disown + +# externo=$(xrandr --query | grep "HDMI1") +# if [ ! "$externo" = "*disconnected*" ]; then +# MONITOR="HDMI1" polybar --reload $bar2 -c ~/.config/polybar/config >>/tmp/$bar2.log 2>&1 & +# fi + +echo "Bars launched..." |