summaryrefslogtreecommitdiff
path: root/modules/system
diff options
context:
space:
mode:
Diffstat (limited to 'modules/system')
-rw-r--r--modules/system/launchd.nix8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/system/launchd.nix b/modules/system/launchd.nix
index e0d2a62..7a70e1a 100644
--- a/modules/system/launchd.nix
+++ b/modules/system/launchd.nix
@@ -12,22 +12,22 @@ let
};
launchdActivation = basedir: target: ''
- if ! diff '${cfg.build.launchd}/Library/${basedir}/${target}' '/Library/${basedir}/${target}'; then
+ if ! diff '${cfg.build.launchd}/Library/${basedir}/${target}' '/Library/${basedir}/${target}' &> /dev/null; then
if test -f '/Library/${basedir}/${target}'; then
launchctl unload -w '/Library/${basedir}/${target}' || true
fi
cp -f '${cfg.build.launchd}/Library/${basedir}/${target}' '/Library/${basedir}/${target}'
- launchctl load '/Library/${basedir}/${target}'
+ launchctl load -w '/Library/${basedir}/${target}'
fi
'';
userLaunchdActivation = target: ''
- if ! diff ${cfg.build.launchd}/user/Library/LaunchAgents/${target} ~/Library/LaunchAgents/${target}; then
+ if ! diff ${cfg.build.launchd}/user/Library/LaunchAgents/${target} ~/Library/LaunchAgents/${target} &> /dev/null; then
if test -f ~/Library/LaunchAgents/${target}; then
launchctl unload -w ~/Library/LaunchAgents/${target} || true
fi
cp -f '${cfg.build.launchd}/user/Library/LaunchAgents/${target}' ~/Library/LaunchAgents/${target}
- launchctl load ~/Library/LaunchAgents/${target}
+ launchctl load -w ~/Library/LaunchAgents/${target}
fi
'';