From 2412129204a3691ae4434a2504c16404588d5f3a Mon Sep 17 00:00:00 2001 From: Christoph Urlacher Date: Tue, 22 Jul 2025 13:58:27 +0200 Subject: [PATCH] System: Align system hyprland package with hyprland module --- home/modules/hyprland/default.nix | 9 +++++---- system/default.nix | 6 +++++- system/modules/desktopportal/default.nix | 7 ++++--- 3 files changed, 14 insertions(+), 8 deletions(-) diff --git a/home/modules/hyprland/default.nix b/home/modules/hyprland/default.nix index 4e809b1f..5cfe849c 100644 --- a/home/modules/hyprland/default.nix +++ b/home/modules/hyprland/default.nix @@ -10,20 +10,21 @@ }: let inherit (config.modules) hyprland color; + # Autostart programs + always-exec = import ./autostart.nix {inherit lib pkgs config hyprland;}; + + # Keybindings always-bind = import ./mappings.nix {inherit lib config hyprland;}; + # Mousebindings always-bindm = { "$mainMod, mouse:272" = ["movewindow"]; "$mainMod, mouse:273" = ["resizewindow"]; }; - - always-exec = import ./autostart.nix {inherit lib pkgs config hyprland;}; in { options.modules.hyprland = import ./options.nix {inherit lib mylib;}; config = lib.mkIf hyprland.enable { - # Some assertion is not possible if HM is used standalone, - # because nixosConfig won't be available. assertions = [ { assertion = nixosConfig.programs.hyprland.enable; diff --git a/system/default.nix b/system/default.nix index ce608d28..1cf60022 100644 --- a/system/default.nix +++ b/system/default.nix @@ -213,7 +213,7 @@ with mylib.networking; { }; # https://github.com/NixOS/nixpkgs/issues/179486 - supportedLocales = ["en_US.UTF-8/UTF-8" "de_DE.UTF-8/UTF-8"]; + supportedLocales = ["${en}/UTF-8" "${de}/UTF-8"]; }; console = { @@ -339,6 +339,10 @@ with mylib.networking; { hyprland = { enable = !headless; + + package = inputs.hyprland.packages.${system}.hyprland; + portalPackage = inputs.hyprland.packages.${system}.xdg-desktop-portal-hyprland; + xwayland.enable = true; withUWSM = true; }; diff --git a/system/modules/desktopportal/default.nix b/system/modules/desktopportal/default.nix index 75ee9915..86fc9072 100644 --- a/system/modules/desktopportal/default.nix +++ b/system/modules/desktopportal/default.nix @@ -43,9 +43,10 @@ in { xdg-desktop-portal-gtk # Fallback ] - (lib.mkIf desktopportal.hyprland.enable [ - xdg-desktop-portal-hyprland - ]) + # We don't need to install that explicitly + # (lib.mkIf desktopportal.hyprland.enable [ + # xdg-desktop-portal-hyprland + # ]) (lib.mkIf desktopportal.termfilechooser.enable [ xdg-desktop-portal-termfilechooser # Filechooser using yazi