diff options
author | Jörg Thalheim <Mic92@users.noreply.github.com> | 2024-06-05 09:57:53 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-05 09:57:53 +0200 |
commit | 7d98bbfcd57c3cecb5b25e1fc4c3f3604903cfb7 (patch) | |
tree | 2bfb21cb0a430322a8691ef223323932552a085c /nixos/modules | |
parent | 9028937bc4913fcc3d1449d16920e273e64d7bd7 (diff) | |
parent | de777188870259d3a1633a41dad963cc19bee6a1 (diff) |
Merge pull request #315827 from JohnRTitor/hyprland-module
nixos/{hyprland, wayland-common}: disable wlr portal for hyprland, enable xdg autostart for all wayland compositors
Diffstat (limited to 'nixos/modules')
-rw-r--r-- | nixos/modules/programs/wayland/hyprland.nix | 5 | ||||
-rw-r--r-- | nixos/modules/programs/wayland/river.nix | 2 | ||||
-rw-r--r-- | nixos/modules/programs/wayland/sway.nix | 2 | ||||
-rw-r--r-- | nixos/modules/programs/wayland/wayland-session.nix | 15 |
4 files changed, 18 insertions, 6 deletions
diff --git a/nixos/modules/programs/wayland/hyprland.nix b/nixos/modules/programs/wayland/hyprland.nix index f5ca741f94328..98779ea7d03a3 100644 --- a/nixos/modules/programs/wayland/hyprland.nix +++ b/nixos/modules/programs/wayland/hyprland.nix @@ -69,7 +69,8 @@ in (import ./wayland-session.nix { inherit lib pkgs; - xwayland = cfg.xwayland.enable; + enableXWayland = cfg.xwayland.enable; + enableWlrPortal = false; # Hyprland has its own portal, wlr is not needed }) ]); @@ -87,4 +88,6 @@ in "Nvidia patches are no longer needed" ) ]; + + meta.maintainers = with lib.maintainers; [ fufexan ]; } diff --git a/nixos/modules/programs/wayland/river.nix b/nixos/modules/programs/wayland/river.nix index 0980bd28cf828..6391f00e2f626 100644 --- a/nixos/modules/programs/wayland/river.nix +++ b/nixos/modules/programs/wayland/river.nix @@ -57,7 +57,7 @@ in (import ./wayland-session.nix { inherit lib pkgs; - xwayland = cfg.xwayland.enable; + enableXWayland = cfg.xwayland.enable; }) ]); diff --git a/nixos/modules/programs/wayland/sway.nix b/nixos/modules/programs/wayland/sway.nix index 31821a84a5bd7..e3e32aa7a56ab 100644 --- a/nixos/modules/programs/wayland/sway.nix +++ b/nixos/modules/programs/wayland/sway.nix @@ -140,7 +140,7 @@ in (import ./wayland-session.nix { inherit lib pkgs; - xwayland = cfg.xwayland.enable; + enableXWayland = cfg.xwayland.enable; }) ]); diff --git a/nixos/modules/programs/wayland/wayland-session.nix b/nixos/modules/programs/wayland/wayland-session.nix index e9c12da156abc..877b106684700 100644 --- a/nixos/modules/programs/wayland/wayland-session.nix +++ b/nixos/modules/programs/wayland/wayland-session.nix @@ -1,4 +1,9 @@ -{ lib, pkgs, xwayland ? true }: +{ + lib, + pkgs, + enableXWayland ? true, + enableWlrPortal ? true, +}: { security = { @@ -11,8 +16,12 @@ programs = { dconf.enable = lib.mkDefault true; - xwayland.enable = lib.mkDefault xwayland; + xwayland.enable = lib.mkDefault enableXWayland; }; - xdg.portal.wlr.enable = lib.mkDefault true; + xdg.portal.wlr.enable = enableWlrPortal; + + # Window manager only sessions (unlike DEs) don't handle XDG + # autostart files, so force them to run the service + services.xserver.desktopManager.runXdgAutostartIfNone = lib.mkDefault true; } |