1
0
Fork 0
mirror of https://github.com/LnL7/nix-darwin.git synced 2024-12-14 11:57:34 +00:00

launchd: fix activation diff

This commit is contained in:
Daiderd Jordan 2017-05-11 21:47:34 +02:00
parent c7d92b852e
commit a2843f8192
No known key found for this signature in database
GPG key ID: D02435D05B810C96

View file

@ -14,7 +14,7 @@ let
};
launchdActivation = basedir: target: ''
if ! diff '/run/current-system/Library/${basedir}/${target}' '/Library/${basedir}/${target}'; then
if ! diff '${cfg.build.launchd}/Library/${basedir}/${target}' '/Library/${basedir}/${target}'; then
if test -f '/Library/${basedir}/${target}'; then
launchctl unload -w '/Library/${basedir}/${target}' || true
fi
@ -24,7 +24,7 @@ let
'';
userLaunchdActivation = target: ''
if ! diff '/run/current-system/${home}/Library/LaunchAgents/${target}' '${home}/Library/LaunchAgents/${target}'; then
if ! diff '${cfg.build.launchd}/${home}/Library/LaunchAgents/${target}' '${home}/Library/LaunchAgents/${target}'; then
if test -f '${home}/Library/LaunchAgents/${target}'; then
launchctl unload -w '${home}/Library/LaunchAgents/${target}' || true
fi