nixos/niri: add nautilus to systemPackages (#461501)
This commit is contained in:
@@ -12,12 +12,22 @@ in
|
||||
enable = lib.mkEnableOption "Niri, a scrollable-tiling Wayland compositor";
|
||||
|
||||
package = lib.mkPackageOption pkgs "niri" { };
|
||||
|
||||
useNautilus = lib.mkEnableOption "Nautilus as file-chooser for xdg-desktop-portal-gnome" // {
|
||||
default = true;
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable (
|
||||
lib.mkMerge [
|
||||
{
|
||||
environment.systemPackages = [ cfg.package ];
|
||||
environment.systemPackages = [
|
||||
cfg.package
|
||||
]
|
||||
# Required for xdg-desktop-portal-gnome's FileChooser to work properly
|
||||
++ lib.optionals cfg.useNautilus [
|
||||
pkgs.nautilus
|
||||
];
|
||||
|
||||
services = {
|
||||
displayManager.sessionPackages = [ cfg.package ];
|
||||
@@ -34,6 +44,10 @@ in
|
||||
|
||||
configPackages = [ cfg.package ];
|
||||
|
||||
config.niri = lib.mkIf (!cfg.useNautilus) {
|
||||
"org.freedesktop.impl.portal.FileChooser" = lib.mkDefault "gtk";
|
||||
};
|
||||
|
||||
# Recommended by upstream, required for screencast support
|
||||
# https://github.com/YaLTeR/niri/wiki/Important-Software#portals
|
||||
extraPortals = [ pkgs.xdg-desktop-portal-gnome ];
|
||||
|
||||
Reference in New Issue
Block a user