MyNixOS website logo
option

launchd.agents.<name>.restartTriggers

Dependencies whose changed identities restart an already running agent during activation. These do not watch files for changes. Stopped agents are not started. Adding the first trigger or removing the last trigger also counts as a change. Applied state is kept in $XDG_STATE_HOME/home-manager/launchd.

Changes to the plist or domain still use the normal agent replacement behavior. Switching to or from a generation built before this option was available can require a manual restart for configuration-only changes, because those activation scripts do not maintain trigger state.

Running state is read from launchctl's diagnostic output, which is not a stable API. An unrecognized state fails activation. The job can stop between this check and kickstart, which may then start it. An interruption after restarting but before saving state can cause a retry.

Declarations
Type
list of (string or absolute path or package)
Default
[ ]
Example
[ config.xdg.configFile."example/config".source ]