diff --git a/modules/wms/wayland/niri/module.nix b/modules/wms/wayland/niri/module.nix new file mode 100644 index 0000000..fd08d72 --- /dev/null +++ b/modules/wms/wayland/niri/module.nix @@ -0,0 +1,31 @@ +{ + config, + lib, + pkgs, + ... +}: let + cfg = config.programs.niri; + inherit (pkgs) xdg-desktop-portal-gtk xdg-desktop-portal-gnome; +in { + programs.niri = { + enable = true; + }; + programs.xwayland.enable = lib.mkForce false; + services.gnome.gnome-keyring.enable = lib.mkForce false; + environment.systemPackages = builtins.attrValues { + inherit (pkgs) wmenu swaylock; + }; + + xdg.portal = { + enable = lib.mkDefault true; + + configPackages = [cfg.package]; + + # Recommended by upstream, required for screencast support + # https://github.com/YaLTeR/niri/wiki/Important-Software#portals + extraPortals = [ + xdg-desktop-portal-gnome + xdg-desktop-portal-gtk + ]; + }; +}