We have moved to a new Sailfish OS Forum. Please start new discussions there.
4

Trigger CalDAV sync from command line? [answered]

asked 2014-07-09 19:30:36 +0200

lechris gravatar image

updated 2014-07-09 19:31:40 +0200

According to https://together.jolla.com/question/45519/caldav-manual-syncing-is-it-working/ and https://together.jolla.com/question/45288/sync-from-pulley-menu-in-caldav-account-does-not-work/ there seems to be an issue with syncing CalDAV account with 1.0.7.16. Is there a way to trigger syncing a CalDAV account from the command line?

I'd like to watch the journal while playing around with syncing calendars. It seems to me that my CalDAV accound gets synced from time to time. But I can't figure out in which intervals. It does not seem to happen at the set up quarter hour interval. Events created or moved on the phone did not appear online before the next day. A newly calendar created and shared at the server did not show up until now.

edit retag flag offensive reopen delete

The question has been closed for the following reason "the question is answered, an answer was accepted" by eric
close date 2014-07-10 11:11:09.443901

1 Answer

Sort by » oldest newest most voted
3

answered 2014-07-09 21:56:59 +0200

Fuzzillogic gravatar image

Based on the N9/Buteo, you can try this, as normal user (nemo):

dbus-send --session --print-reply --dest=com.meego.msyncd /synchronizer com.meego.msyncd.startSync string:'caldav-sync'

I don't use CalDAV but SyncML, so I can't be certain this is will actually work for CalDAV. It should respond with "boolean true" if successful, otherwise you'll get "boolean false".

edit flag offensive delete publish link more

Comments

I tried this command earlier today and it doesn't seem to work. You get true response, but server log shows no requests.

koudi ( 2014-07-09 23:18:06 +0200 )edit

@Fuzzillogic Thank you very much for this starting point! Invoking the command above leads to [C] CalDavClient::initConfig:287 - no account id specified, "accountid" not found in profile and [C] NotebookSyncAgent::fetchRemoteChanges:221 - void NotebookSyncAgent::fetchRemoteChanges(const QDateTime&, const QDateTime&)which in turn let me stumble over https://github.com/nemomobile/buteo-sync-plugin-caldav which I did not know before.

lechris ( 2014-07-10 02:22:18 +0200 )edit
4

The "caldav-sync" profile is the "template" profile. Per-account profiles are generated from this template profile. So, what you need to do is trigger the per-account profile which was generated for your caldav account. This will be something like "caldav-sync-6" or "caldav-sync-19" or something depending on the account Id of your caldav account. You can do devel-su -p ls -al /home/nemo/.cache/msyncd/sync/ to find out which sync profiles are currently installed.

chris.adams ( 2014-07-10 04:13:37 +0200 )edit
1

@chris.adams is right, this is working. Thank you.

koudi ( 2014-07-10 08:57:44 +0200 )edit
1

@chris.adams Thank you! I recreated the CalDAV account meanwhile and put the whole URL in the server field (this time?) as suggested by https://together.jolla.com/question/45179/caldav-owncloud/?answer=45186#post-id-45186. The manual synchronization with the actual account number suffix updated entries in both directions.

lechris ( 2014-07-12 01:40:26 +0200 )edit

Question tools

Follow
8 followers

Stats

Asked: 2014-07-09 19:30:36 +0200

Seen: 784 times

Last updated: Jul 09 '14