mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 14:54:29 +01:00
nixos/xdg/portal: set GTK_USE_PORTAL with lib.mkIf
If lib.optional is given a false value it will return an empty list. Thusly the set-environment script can have ``` export GTK_USE_PORTAL= ``` This can rub certain bugs the wrong way #65679 so lets make sure this isn't set in the environment at all.
This commit is contained in:
parent
c2c77e7824
commit
64b4a24047
1 changed files with 1 additions and 1 deletions
|
@ -51,7 +51,7 @@ with lib;
|
|||
systemd.packages = packages;
|
||||
|
||||
environment.variables = {
|
||||
GTK_USE_PORTAL = optional cfg.gtkUsePortal "1";
|
||||
GTK_USE_PORTAL = mkIf cfg.gtkUsePortal "1";
|
||||
XDG_DESKTOP_PORTAL_PATH = map (p: "${p}/share/xdg-desktop-portal/portals") cfg.extraPortals;
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue