mirror of
https://github.com/nix-community/home-manager
synced 2024-11-18 17:19:45 +01:00
xfconf: fix dbus may not be started in the startup of NixOS. (#3707)
This commit is contained in:
parent
3c18113bd7
commit
68ba595783
1 changed files with 14 additions and 1 deletions
|
@ -97,6 +97,19 @@ in {
|
||||||
commands = mapAttrsToList
|
commands = mapAttrsToList
|
||||||
(channel: properties: mapAttrsToList (mkCommand channel) properties)
|
(channel: properties: mapAttrsToList (mkCommand channel) properties)
|
||||||
cfg.settings;
|
cfg.settings;
|
||||||
in concatMapStrings concatStrings commands);
|
|
||||||
|
load = pkgs.writeShellScript "load-xfconf"
|
||||||
|
(concatMapStrings concatStrings commands);
|
||||||
|
in ''
|
||||||
|
if [[ -v DBUS_SESSION_BUS_ADDRESS ]]; then
|
||||||
|
export DBUS_RUN_SESSION_CMD=""
|
||||||
|
else
|
||||||
|
export DBUS_RUN_SESSION_CMD="${pkgs.dbus}/bin/dbus-run-session --dbus-daemon=${pkgs.dbus}/bin/dbus-daemon"
|
||||||
|
fi
|
||||||
|
|
||||||
|
$DRY_RUN_CMD $DBUS_RUN_SESSION_CMD ${load}
|
||||||
|
|
||||||
|
unset DBUS_RUN_SESSION_CMD
|
||||||
|
'');
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue