dotfiles/dot_local/bin/executable_waybar-launcher

15 lines
407 B
Bash

#!/bin/bash
# Terminate already running bar instances
killall -q waybar
# Wait until the processes have been shut down
while pgrep -u $UID -x waybar >/dev/null; do sleep 1; done
# Make sure pipewire-pulse is running or module won't load
until pgrep -u $UID -x pipewire-pulse >/dev/null; do sleep 1; done
# Launch Waybar
echo "---" | tee -a /tmp/waybar.log
waybar 2>&1 | tee -a /tmp/waybar.log & disown