summaryrefslogtreecommitdiff
path: root/modules/programs/bash
diff options
context:
space:
mode:
authorTyler Miller <tmillr@proton.me>2023-06-29 00:50:28 -0700
committerTyler Miller <tmillr@proton.me>2024-06-09 11:20:15 -0700
commit861af0fc94df9454f4e92d6892f75588763164bb (patch)
tree5641177f735e7cdcfa22d2bb8c7b5628cdb2d58a /modules/programs/bash
parentc0d5b8c54d6828516c97f6be9f2d00c63a363df4 (diff)
fix(launchd): improve `StartCalendarInterval`
Stricter launchd -> StartCalendarInterval type: - Verify that the integers passed to `Minute`, `Hour`, etc. are within range. - When provided, the value for StartCalendarInterval must be a non-empty list of calendar intervals and must not contain duplicates entries (throw an error otherwise). - For increased flexibility and backwards-compatibility, allow an attrset to be passed as well (which will be type-checked and is functionally equivalent to passing a singleton list). Allowing an attrset or list is precisely in-line with what `launchd.plist(5)` accepts for StartCalendarInterval. Migrate `nix.gc.interval` and `nix.optimise.interval` over to use this new type, and update their defaults to run weekly instead of daily. Create `modules/launchd/types.nix` file for easier/modular use of launchd types needed in multiple files. Documentation: - Update and improve wording/documentation of launchd's `StartCalendarInterval`. - Improve wording/documentation of `nix.gc.interval` and `nix.optimise.interval` ("time interval" can be misleading as it's actually a "calendar interval"; e.g. `{ Hour = 3; Minute = 15;}` runs daily, not every 3.25 hours).
Diffstat (limited to 'modules/programs/bash')
0 files changed, 0 insertions, 0 deletions