From d89706736cb9015432d3c3b43683faf1bf4685df Mon Sep 17 00:00:00 2001 From: rope Date: Mon, 18 May 2026 10:35:26 +0100 Subject: [PATCH] hyprpaper: remove unnecessary wallpaper workarounds The mkForce wallpaper override (explicit monitor names) and the IPC startup script (sleep 2 + hyprctl) were stacked workarounds for a misdiagnosed hyprpaper 0.8.4 bug. Stylix's hyprpaper target (still auto-enabled) correctly sets preload and wallpaper with the standard wildcard syntax. Co-Authored-By: Claude Opus 4.6 --- settings/hyprland.nix | 20 +++----------------- 1 file changed, 3 insertions(+), 17 deletions(-) diff --git a/settings/hyprland.nix b/settings/hyprland.nix index 6f485a2..0e8c87b 100644 --- a/settings/hyprland.nix +++ b/settings/hyprland.nix @@ -106,17 +106,11 @@ in # into settings.config below. stylix.targets.hyprland.enable = false; - # Hyprpaper was previously started by stylix's Hyprland target; keep it. + # The disabled Hyprland target would normally enable this; do it + # manually. Stylix's hyprpaper target (auto-enabled) still handles + # preload/wallpaper settings. services.hyprpaper.enable = true; - # hyprpaper 0.8.4 doesn't honour the Stylix-generated "wallpaper=," - # (empty monitor = all) wildcard — the monitor stays unmapped. Override - # with explicit monitor names using config.stylix.image to avoid the - # circular dependency that arises from referencing services.hyprpaper.settings.preload. - services.hyprpaper.settings.wallpaper = lib.mkForce [ - "${if isGaming then "DP-2" else "eDP-1"},${config.stylix.image}" - ]; - wayland.windowManager.hyprland = { enable = true; configType = "lua"; @@ -206,13 +200,6 @@ in extraConfig = let - # hyprpaper 0.8.4 bug: wallpaper= in config is silently ignored. - # preload= works; set the wallpaper via IPC after startup. - setWallpaper = pkgs.writeShellScript "set-hyprpaper-wallpaper" '' - sleep 2 - wallpaper=$(grep '^preload=' "$HOME/.config/hypr/hyprpaper.conf" | head -1 | cut -d= -f2-) - ${hyprland-pkgs.hyprland}/bin/hyprctl hyprpaper wallpaper "${if isGaming then "DP-2" else "eDP-1"},$wallpaper" - ''; powerMenu = pkgs.writeShellScript "power-menu" '' choice=$(printf '%s\n' \ $'\uf023 Lock' \ @@ -275,7 +262,6 @@ in hl.exec_cmd("hyprctl setcursor Bibata-Modern-Ice 24") hl.exec_cmd("swayosd-server") ${lib.optionalString isMacbook ''hl.exec_cmd("hypridle")''} - hl.exec_cmd("${setWallpaper}") end) -- Animation curve and definitions