WIP: Add recurring reminders and editable end dates - #110
Draft
morozovpersonal wants to merge 3 commits into
Draft
WIP: Add recurring reminders and editable end dates#110morozovpersonal wants to merge 3 commits into
morozovpersonal wants to merge 3 commits into
Conversation
Implements EKRecurrenceRule-backed recurrence, requested in keith#104: - `reminders add <list> <reminder> --repeat daily|weekly|monthly|yearly` - `--repeat-interval N` to repeat every N units instead of every 1 (default 1), e.g. `--repeat-interval 2 --repeat weekly` for fortnightly. - `--repeat-until <date>` to set a recurrence end date; omitting it repeats forever, matching Reminders.app's own default. - `reminders edit <list> <index> --repeat ...` replaces an existing repeat rule; `--clear-repeat` removes it entirely. - JSON output (`--format json`) now includes `recurrence`, `recurrenceInterval`, and `recurrenceEnd` fields when a reminder has a recurrence rule, so scripts consuming `reminders show --format json` can see it. `hourly` is intentionally rejected with a clear validation error rather than silently degrading to a daily rule: EventKit's `EKRecurrenceFrequency` has no hourly case (Reminders.app's own UI doesn't expose hourly repeat either), so there's no faithful way to represent it via `EKRecurrenceRule`. Tested live against real Reminders.app data (add with daily/weekly/ monthly + custom interval + end date, edit to replace and to clear, hourly correctly rejected, --repeat-interval/--repeat-until correctly rejected without --repeat, conflicting --repeat + --clear-repeat correctly rejected). Added Tests/RemindersTests/RecurrenceTests.swift covering the frequency mapping, interval, end-date, and representability logic at the unit level. Note on test execution: this dev environment currently has only Command Line Tools installed (no full Xcode), so `swift test` can't link XCTest here (`xcrun --find xctest` fails) -- this affects the pre-existing NaturalLanguageTests.swift identically, so it's an environment gap, not something this change introduces. `swift build` succeeds cleanly and all behavior was verified against the live binary instead; the new test file is plain XCTest and should run normally under CI or on a machine with full Xcode.
morozovpersonal
marked this pull request as draft
August 24, 2026 17:25
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Context and attribution
This PR starts from Ramesh Baskaran's recurrence implementation in #109 (commit
8891097d32f1487a7b051a89ffa6b4459d4b9cc7). That commit and its original authorship are preserved as the first commit here. #109 currently conflicts withmainafter #108, so this branch reapplies that work to the current base and extends it with safe end-date editing.Closes #84.
Closes #104.
What it adds
--repeat daily|weekly|monthly|yearly,--repeat-interval, and--repeat-untilonaddedit, including end-only--repeat-until,--clear-repeat-end, and--clear-repeatEdit safety
recurrenceEnd, preserving provider-specific calendar metadata and complex selectorsVerification
swift build -Xswiftc -warnings-as-errorsRecurrenceTestspassrecurrenceEnd; no reminder data was changedOn the local macOS 26 SDK, the full 37-test suite has three pre-existing
NaturalLanguageTestsexpectation failures because Foundation now includesdayOfYearin parsedDateComponents. All recurrence tests pass, and the recurrence changes do not touch that parser behavior.