diff options
| author | Ruben Maher <ruben@maher.fyi> | 2022-04-17 10:45:22 +0900 |
|---|---|---|
| committer | Ruben Maher <ruben@maher.fyi> | 2022-04-17 10:45:22 +0900 |
| commit | 11c98bfad4806f08b9c3a94f5269ce80ce286f66 (patch) | |
| tree | e635303bba675170d02f23b7ad032e977fd801c4 /modules/launchd | |
| parent | 4fdbb8168f61d31d3f90bb0d07f48de709c4fe79 (diff) | |
feat: add serviceConfig.LaunchEvents configuration option
This is required if you want to register an "xpc event stream handler". Check
out the README for https://github.com/snosrap/xpc_set_event_stream_handler for
more info.
Diffstat (limited to 'modules/launchd')
| -rw-r--r-- | modules/launchd/launchd.nix | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/modules/launchd/launchd.nix b/modules/launchd/launchd.nix index e903c99..a3ea918 100644 --- a/modules/launchd/launchd.nix +++ b/modules/launchd/launchd.nix @@ -708,6 +708,31 @@ with lib; }); }; + LaunchEvents = mkOption { + type = types.nullOr (types.attrs); + default = null; + description = '' + Specifies higher-level event types to be used as launch-on-demand event + sources. Each sub-dictionary defines events for a particular event + subsystem, such as "com.apple.iokit.match-ing", which can be used to + launch jobs based on the appearance of nodes in the IORegistry. Each + dictionary within the sub-dictionary specifies an event descriptor that + is specified to each event subsystem. With this key, the job promises to + use the xpc_set_event_stream_handler(3) API to consume events. See + xpc_events(3) for more details on event sources. + ''; + example = { + "com.apple.iokit.matching" = { + "com.apple.usb.device" = { + IOMatchLaunchStream = true; + IOProviderClass = "IOUSBDevice"; + idProduct = "*"; + idVendor = "*"; + }; + }; + }; + }; + Sockets = mkOption { default = null; description = '' |
