From mboxrd@z Thu Jan 1 00:00:00 1970 From: Torsten Wagner Subject: Re: org-caldav: Sync Org with external calendars through CalDAV (Owncloud, Google, ...) Date: Wed, 25 Jul 2012 17:18:13 +0900 Message-ID: References: <87r4senoly.fsf@engster.org> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Return-path: Received: from eggs.gnu.org ([208.118.235.92]:55023) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1StwnT-0005f6-V9 for emacs-orgmode@gnu.org; Wed, 25 Jul 2012 04:18:24 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1StwnO-0008KN-GH for emacs-orgmode@gnu.org; Wed, 25 Jul 2012 04:18:19 -0400 Received: from mail-vc0-f169.google.com ([209.85.220.169]:54239) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1StwnO-0008KB-CR for emacs-orgmode@gnu.org; Wed, 25 Jul 2012 04:18:14 -0400 Received: by vcbfl10 with SMTP id fl10so394919vcb.0 for ; Wed, 25 Jul 2012 01:18:13 -0700 (PDT) In-Reply-To: <87r4senoly.fsf@engster.org> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Hey David, herewith I claim interest but currently lack of time to test it... just to keep you motivated ;) Guess many are interested actually, this was on the mailing list several times already. Any chance to merge with mobileOrg? Would be good to have both ways and you might save some time doing redundant stuff in both projects. Torsten On 15 July 2012 04:12, David Engster wrote: > I have written a package 'org-caldav' which can sync items to a remote > calendar server using the CalDAV protocol. The main purpose of this > package is to make better use of Org in combination with Android-based > mobile devices (yes, there is mobileOrg, but I have several problems > with it; that's a topic for another day, though). > > I think org-caldav is now "good enough" to allow some testing by > adventurous people. I put the code up on github here > > https://github.com/dengste/org-caldav > > I've tested the code with my Owncloud server and also with Google > Calendar. Please see the Readme on how to set things up. Most > importantly, please use a new, dedicated calendar for testing this > package; do *not* use your precious main calendar. Also, while > org-caldav should only access the calendar you provide through > `org-caldav-calendar-id', you should have a backup of all your calendar > data, just in case. > > The initial sync can take some time, depending on the number of > events. Especially the CalDAV interface to Google can be quite slow at > times. If the initial sync aborts for any reason, just run > `org-caldav-sync' again. Note that after the initial sync, only new > events will be transferred, so things should become much snappier. > > A few further notes regarding the code: > > I am relying mainly on three other packages to do the real heavy > lifting, which is also why org-caldav is actually pretty small: > > - url-dav.el for talking to WebDAV servers (CalDAV is essentially WebDAV > with a few extensions). Unfortunately, the current version of url-dav > that is shipping with Emacs is broken for practically all CalDAV > servers (see bug #11916), which is why I provide a patched version of > url-dav.el in the above repository. You have to make sure that this > patched version is loaded instead of the one in Emacs proper. I am > hoping that this will be fixed in Emacs 24.2. > > - org-icalendar.el is doing all the conversion from org to icalendar > events which are needed for CalDAV. This has the advantage that you > can use all the variables from that package to control how things > should be exported. The only exception is the actual org files being > searched for time stamps, which is determined through > `org-caldav-files'. > > - icalendar.el for parsing events from CalDAV. I took some code from > that package to generate org items from the calendar events. > > The syncing between org and the external calendar is not yet really > finished. I would like to have proper two-way-syncing so that you can > freely change events on any side, but this is rather difficult to do and > I'd first like to get some feedback on the current code. Also, I have > a hunch that some Org experts around here might have some good ideas on > how to properly implement this. > > Here's what the code can currently do: > > - All items in `org-caldav-files' with active time stamps are synced to > the calendar. > > - If you change an item in one of those files in orgmode, this change > will also get synced to the external calendar (to be exact: this will > generate a new event and the old one will be deleted). > > - If you create a *new* event in the calendar through Android or any > other client (like browser), this event will land in the > `org-caldav-inbox' file as an org item. > > However: > > - If you *change* an item directly on the CalDAV server, this will *not* > get synced back to Org. What happens exactly depends on the server > (whether it renames the event or not). Just try it out. The item might > even get deleted after the next sync - you have been warned. > > - Likewise, if you *change* and item in `org-caldav-inbox', this will > not get synced back to the calendar. > > OK, this has gotten way too long already. Please try it out and let me > know how it goes. > > Cheers, > David >