summaryrefslogtreecommitdiff
path: root/launch_waybar.sh
diff options
context:
space:
mode:
Diffstat (limited to 'launch_waybar.sh')
-rwxr-xr-xlaunch_waybar.sh5
1 files changed, 4 insertions, 1 deletions
diff --git a/launch_waybar.sh b/launch_waybar.sh
index 9a0e04a..3e1233e 100755
--- a/launch_waybar.sh
+++ b/launch_waybar.sh
@@ -2,9 +2,12 @@
killall waybar
+WC="$(crcparse WC)"
+CALLED="${1:-$WC}"
+
if type "wlr-randr"; then
for m in $(wlr-randr | grep -B5 'Enabled: yes' | sed '/^\s\s*/d;/^--$/d' | cut -d' ' -f1); do
- waybar -c "$XDG_CONFIG_HOME"/waybar/config-$1-$m &
+ waybar -c "$XDG_CONFIG_HOME"/waybar/config-$CALLED-$m &
done
else
waybar