From 20a3990979a3c4863fddae327132b0b87d1e245f Mon Sep 17 00:00:00 2001 From: alexion Date: Sun, 11 Oct 2026 22:43:35 -0400 Subject: [PATCH] refactor(theming): simplify stylix module --- .../nixos/modules/desktop/utilities/theming.nix | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/configs/nixos/modules/desktop/utilities/theming.nix b/configs/nixos/modules/desktop/utilities/theming.nix index 15da478..45a65b4 100644 --- a/configs/nixos/modules/desktop/utilities/theming.nix +++ b/configs/nixos/modules/desktop/utilities/theming.nix @@ -6,15 +6,13 @@ }: # Nord theming for the graphical layer, driven from one base16 scheme by Stylix. let - # A single static Nord wallpaper, drawn as a vertical gradient across the # Polar Night shades so it needs no committed binary and no network fetch. wallpaper = pkgs.runCommand "nord-wallpaper.png" { } '' - ${pkgs.imagemagick}/bin/magick \ + ${lib.getExe pkgs.imagemagick} \ -size 2560x1440 gradient:'#2E3440'-'#3B4252' \ "$out" ''; - user = config.user.name; in { options.modules.desktop.utilities.theming.enable = @@ -58,12 +56,8 @@ in }; }; }; - registry.env.${config.networking.hostName} = { - HYPRCURSOR_THEME = config.stylix.cursor.name; - HYPRCURSOR_SIZE = toString config.stylix.cursor.size; - }; - home-manager.users.${user} = { + home-manager.users.${config.user.name} = { # Stylix drives the cursor through home-manager's pointer-cursor config, # whose generation must be switched on explicitly. home.pointerCursor.enable = true; @@ -72,5 +66,10 @@ in # base16 mapping Stylix would apply, so its target stays off. stylix.targets.nixvim.enable = false; }; + + registry.env.${config.networking.hostName} = { + HYPRCURSOR_THEME = config.stylix.cursor.name; + HYPRCURSOR_SIZE = toString config.stylix.cursor.size; + }; }; } -- 2.47.3