On Sun, 06 May 2007 16:11:13 +0200, "Luca Capello" <[EMAIL PROTECTED]> said:
> While I think my original flowchart is still the best option, it
> implies that emacs is running.  Thus I started thinking about a
> different solution, where all the steps are executed by the OpenSync
> plugin.  This means that the plugin should be able to extracts BBDB
> contacts and then insert them back if modified, maybe performing a
> backup of the BBDB file and writing into a new one.

That's what SyncBBDB does. You have to be careful about the possiblity
of a write conflict between the sync program and a running emacs: if you
have unsaved bbdb changes in emacs when you sync, and you save them
after the sync, you'll wipe out the changes that the sync program made. 
In its default configuration, SyncBBDB avoids this by using emacs client
to tell emacs to evaluate (bbdb-save-bbdb) before syncing and
(bbdb-records) after syncing.  If emacs isn't running, then emacsclient
fails, but then there's no risk so you can just ignore the error.

-Aaron

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
bbdb-info@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bbdb-info
BBDB Home Page: http://bbdb.sourceforge.net/

Reply via email to