Open mgttlinger opened 6 years ago
If you can point out to me what you think needs to be done to implement this and are willing to accept a PR I can try to implement this next week or so
If it is supported like you say it should already work when you sync from org to the calendar. Maybe you can check that out. Then you can check tho org-caldav.el to add the code for the other way round, from the remote calendar to org. That's it.
I guess one difficulty with that feature is that
So what is the status on this? @mgttlinger @grauschnabel
@GAhlekzis I played around with this but was afraid to fuck up our company calendar (to some extent due to little experience with elisp) and had no good solution to the problems I mentioned so I stopped working on it.
I'm not working on this, I use org-clone-subtree-with-time-shift
for recurring events, because i like to handle every event as a single one for documentation purposes (and it is easier to just delete one if it is canceled).
@grauschnabel can you explain how that works exactly?
Recurring events are supported by ox-icalendar, but this only handles the org->cal direction. The other direction is simply not implemented. This would need code that converts RRULE:FREQ to the proper Org timestamp syntax. If you take a look at for instance https://www.kanzaki.com/docs/ical/rrule.html you might guess that this isn't straightforward at all, unfortunately...
But at least partly icalendar.el has implemented this, right?
https://github.com/jwiegley/emacs-release/blob/master/lisp/calendar/icalendar.el#L2117-L2143
Indeed, it generates diary s-expressions for this using diary-float, diary-block etc. I think this should fit right into org, we don't have to make Org timestamps from these, although that would make syncing easier...
Hi, I've tested this quite a bit. Syncing from org to ical is a built-in functionality of the org export, but you'll have to override org-icalendar-with-timestamps
I've opened a PR for this in case anyone wants to try it out. Please back up your files before trying this. :P https://github.com/dengste/org-caldav/pull/216
There's also https://github.com/dengste/org-caldav/pull/217 which has been merged in a branch https://github.com/Thaodan/org-caldav/tree/thaodan/personal_merger with a few additional fixes.
I was so happy to see that org-caldav worked much better than org gcal just to discover that I get no recurring events from the remote :(. Would it be possible to implement it as org-gcal does? When a remote events is recurring we create a subheading and generate occurences with a limit of back and forward (2 weeks back 1 month forward)?
I'm trying out https://github.com/Thaodan/org-caldav/tree/thaodan/personal_merger, and I can't seem to push my org recurring event to ical
:
(straight-use-package '(org-caldav :git git :host github :repo "dengste/org-caldav" :fork (:repo "Thaodan/org-caldav" :branch "thaodan/personal_merger")))
* 18:30-22:30 Meetup
:PROPERTIES:
:ID: e01be4e3-e8d3-4e32-9096-e55e65c3eb57
:END:
<%%(diary-float t 1 1)>
Tech meetup with local nerds
I can see this event in org-agenda
, but when I run:
(setq-default org-caldav-show-sync-results t
org-caldav-debug-level 2)
(org-caldav-sync)
Then check the *org-caldav-debug*
buffer, I find that there are no UIDs in the logs which match the recurring event, and the event doesn't upload to ical
. There are no errors reported:
I have opened a new PR for this: #308
It supports both repeating events and todos.
I initially started by trying to adapt the sexp approach, but while I found this works for Cal->Org (via icalendar.el), I found that sexp timestamp export seems to be broken in Org->Cal (ox-icalendar). So I switched to just using non-sexp repeating timestamps, which I think is preferable in most cases anyways.
I have a little more cleanup to do (tests and documentation) but it should work. Planning to merge it in the coming weeks. In the meantime any testing/feedback is welcome.
Longer term I think sexp timestamps are the right way to handle more complex repeaters (e.g. with UNTIL or COUNT), but this needs to be fixed upstream in ox-icalendar first, and there may also be additional complications in the case of TODOs (how to update the sexp timestamp when marking a repeating task as completed).
The
RRULE:FREQ
entries in ical used for recurring events are currently not used by org-caldav which limits it's usability quite a bit (at least for me).It seems that both icalendar.el and ox-icalendar.el have this functionality implemented, so I guess implementing this should not be too much work.