From ef035c63b49e1b655a045828e6bcea3299eb878f Mon Sep 17 00:00:00 2001 From: Andre Ramnitz Date: Wed, 11 Sep 2024 07:31:05 +0200 Subject: [PATCH] hyprland/waybar: update for hyprland 0.43.0 also fix gammarelay click-actions --- config/dot-config/hypr/hyprland.conf | 9 +++++---- config/dot-config/hypr/scripts/gammarelay-auto-temp.py | 4 ++-- config/dot-config/hypr/scripts/startup.sh | 2 +- config/dot-config/waybar/config.jsonc | 6 +++--- 4 files changed, 11 insertions(+), 10 deletions(-) diff --git a/config/dot-config/hypr/hyprland.conf b/config/dot-config/hypr/hyprland.conf index 0ca6359c..edbf182b 100644 --- a/config/dot-config/hypr/hyprland.conf +++ b/config/dot-config/hypr/hyprland.conf @@ -50,6 +50,7 @@ exec-once = hyprpm enable hyprbars exec-once = ~/.config/hypr/scripts/startup.sh exec-once = hypridle exec-once = foot -s +exec-shutdown = pkill -f '/usr/lib/python-exec/python3.12/python /home/andy/.config/hypr/scripts/gammarelay-auto-temp.py' # Source a file (multi-file configs) # source = ~/.config/hypr/myColors.conf @@ -192,13 +193,13 @@ plugin { bar_text_font = Iosevka Nerd Font Propo bar_text_size = 12 bar_height = 24 - bar_color = rgba(2394ccbb) - # col.text = rgb(000203) + bar_color = $base0D $base0C 40deg + col.text = rgb(000203) bar_part_of_window = true bar_precedence_over_border = true # hyprbars-button = color, size, icon, on-click - hyprbars-button = rgb(ff4040, 22, 󰖭, hyprctl dispatch killactive - hyprbars-button = rgb(eeee11, 22, 󰁌, hyprctl dispatch fullscreen 1 + hyprbars-button = rgba(ff404033), 22, 󰖭, hyprctl dispatch killactive + hyprbars-button = rgba(eeee1133), 22, 󰁌, hyprctl dispatch fullscreen 1 } } diff --git a/config/dot-config/hypr/scripts/gammarelay-auto-temp.py b/config/dot-config/hypr/scripts/gammarelay-auto-temp.py index 5214d9f1..75a3bd77 100755 --- a/config/dot-config/hypr/scripts/gammarelay-auto-temp.py +++ b/config/dot-config/hypr/scripts/gammarelay-auto-temp.py @@ -12,8 +12,8 @@ def mk_time(hours, minutes, seconds=0): TEMP_DAY = 6500.0 TEMP_NIGHT = 3800.0 -DAWN_TIME = mk_time( 6, 30) # 9:00 (Should be > WINDOW) -DUSK_TIME = mk_time(20, 40) # 19:00 (Shoulbe be > WINDOW + DAWN_TIME) +DAWN_TIME = mk_time( 7, 00) # 9:00 (Should be > WINDOW) +DUSK_TIME = mk_time(20, 00) # 19:00 (Shoulbe be > WINDOW + DAWN_TIME) WINDOW = mk_time( 0, 15) # 15m (The time during which the temperature changes gradually until it reaches the desired value) temp = None diff --git a/config/dot-config/hypr/scripts/startup.sh b/config/dot-config/hypr/scripts/startup.sh index 761d1288..0cdeeba1 100755 --- a/config/dot-config/hypr/scripts/startup.sh +++ b/config/dot-config/hypr/scripts/startup.sh @@ -65,7 +65,7 @@ openrgb -p default --startminimized & ! pidof swww-daemon && /usr/bin/swww-daemon > /dev/null 2>&1 & sleep 0.5 && /usr/bin/swww img ~/Bilder/Wallpapers/default.jpg -pkill -f 'python /home/andy/.config/hypr/scripts/gammarelay-auto-temp.py' +pkill -f '/usr/lib/python-exec/python3.12/python /home/andy/.config/hypr/scripts/gammarelay-auto-temp.py' sleep 1 && "/home/andy/.config/hypr/scripts/gammarelay-auto-temp.py" > /dev/null 2>&1 & pidof wl-paste && killall wl-paste diff --git a/config/dot-config/waybar/config.jsonc b/config/dot-config/waybar/config.jsonc index 235dfb4f..2ab84aac 100644 --- a/config/dot-config/waybar/config.jsonc +++ b/config/dot-config/waybar/config.jsonc @@ -312,9 +312,9 @@ "exec": "wl-gammarelay-rs watch {t}", "on-scroll-up": "busctl --user -- call rs.wl-gammarelay / rs.wl.gammarelay UpdateTemperature n +100", "on-scroll-down": "busctl --user -- call rs.wl-gammarelay / rs.wl.gammarelay UpdateTemperature n -100", - "on-click": "busctl --user -- set-property rs.wl-gammarelay / rs.wl.gammarelay Temperature q 6500", - "on-click-right": "test -f /tmp/autotemp.pid && kill $(cat /tmp/autotemp.pid) &", - "on-click-middle": "${HOME}/.config/hypr/scripts/gammarelay-autotemp.py > /dev/null 2>&1 &", + "on-click": "$HOME/.config/hypr/scripts/gammarelay-auto-temp.py > /dev/null 2>&1 &", + "on-click-middle": "busctl --user -- set-property rs.wl-gammarelay / rs.wl.gammarelay Temperature q 6500", + "on-click-right": "pkill -f '/usr/lib/python-exec/python3.12/python /home/andy/.config/hypr/scripts/gammarelay-auto-temp.py'", "interval": "2", }, "custom/gammarelay-brightness": { -- 2.51.2