Hello! On Sun, 06 May 2007 20:38:44 +0200, Aaron Kaplan wrote: > 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.
Oh, I forgot about SyncBBDB, thank you for reminding me about it. > 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. Yes, I'm aware of this possibility. > 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. Well, I'd like to avoid any interaction with emacs, because otherwise I'd more inclined to code a part of the plugin in elisp. Moreover, AFAIK you missed one situation: emacs is running, but `server-start' hasn't been executed, thus emacsclient cannot connect to the running emacs. I think that for now I won't care about this point, putting a big warning about the fact that it's better to save any BBDB changes before syncing :-D Thx, bye, Gismo / Luca ------------------------------------------------------------------------- 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/