Replace waybar launch script with hyprland autostart

This commit is contained in:
Sravan Balaji
2025-04-27 08:52:49 -04:00
parent f2b92f7938
commit 0896e34dee
3 changed files with 6 additions and 35 deletions

View File

@@ -39,7 +39,6 @@
- [[#window-rules][Window Rules]]
- [[#smart-gaps][Smart Gaps]]
- [[#waybar][Waybar]]
- [[#launch-script][Launch Script]]
- [[#start-configuration][Start Configuration]]
- [[#bar][Bar]]
- [[#configuration][Configuration]]
@@ -115,6 +114,10 @@ exec-once = uwsm app -- mycommand --arg1 --arg2
bind = SUPER, E, exec, uwsm app -- pcmanfm-qt.desktop
#+END_EXAMPLE
#+BEGIN_SRC conf :tangle hyprland.conf
exec-once = uwsm app -- waybar --config $HOME/.config/hypr/waybar/config.jsonc --style $HOME/.config/dwl/waybar/style.css
#+END_SRC
** Environment Variables
- [[https://wiki.hyprland.org/Configuring/Environment-variables/][Hyprland Wiki - Configuring - Environment Variables]]
@@ -483,25 +486,6 @@ windowrule = rounding 0, floating:0, onworkspace:f[1]
* Waybar
** Launch Script
#+BEGIN_SRC shell :shebang #!/usr/bin/env bash :tangle waybar/launch.sh
killall waybar || true
until /usr/bin/waybar \
--config $HOME/.config/dwl/waybar/config.jsonc \
--style $HOME/.config/dwl/waybar/style.css;
do
if [ $? -ne 143 ]; then
echo "Dwl Waybar stopped with exit code $?. Respawning..." >&2;
sleep 1;
else
echo "Dwl Waybar manually killed with SIGTERM";
break;
fi
done
#+END_SRC
** Start Configuration
#+BEGIN_SRC jsonc :tangle waybar/config.jsonc

View File

@@ -8,6 +8,8 @@ $terminal = foot
$fileManager = thunar
$menu = rofi -show combi -run-command "uwsm app -- {cmd}"
exec-once = uwsm app -- waybar --config $HOME/.config/hypr/waybar/config.jsonc --style $HOME/.config/dwl/waybar/style.css
general {
gaps_in = 5
gaps_out = 20

View File

@@ -1,15 +0,0 @@
#!/usr/bin/env bash
killall waybar || true
until /usr/bin/waybar \
--config $HOME/.config/dwl/waybar/config.jsonc \
--style $HOME/.config/dwl/waybar/style.css;
do
if [ $? -ne 143 ]; then
echo "Dwl Waybar stopped with exit code $?. Respawning..." >&2;
sleep 1;
else
echo "Dwl Waybar manually killed with SIGTERM";
break;
fi
done