Hi,
I was wondering if it was possible to use the abook datafile in a cloud-synchronized environment. Here is what I thought...
ENVIRONMENT
I want to use abook together with mutt, ... in a way that facilitates sharing my addressbook not only locally on my server (i.e. by configuring and accessing the datafile in /home/pi/.abook/addressbook
from different local applications) but also access the addressbook via NextCloud service, synchronizing a dedicated local folder on the server (not below .abook
) with a remote service. Please see theattached concept drawing.
CONCEPT
I would like to make the current and default addressbook
file within /home/pi/.abook/
a symbolic link to a file within my dedicated, synchronized folder (e.g. /home/pi/NEXTCLOUD/_TXT/addressbook
). Thus, I could freely read and write the addressbook file at the synchronized location. Any change would be readable by the abook application, as it would trigger the symbolic link to the synchronized file.
PROBLEM
When I change any address using the abook application, it overwrites my symbolic link with a "real" addressbook file, thus breaking my synchronization chain and decoupling the two addressbook files.
REQUEST
Would it be possible to, first, evaluate the configured addressbook file before writing to it. If the addressbook in the first place file was a symbolic link, then don't overwrite it but follow the link to the other end and finally overwrite the file found there.
What do you think?
I would even be able to try to implement it myself, if the idea was good but the time was missing on the main developer's sides.
Any questions?
Thanks.
I think the right approach is to use the
--datafile
flag everywhere you want to use a custom location.I'd be less "magic" than a symlink and more predictable.
There have been an attempt into respecting XDG standards (which would apply to the data directory)
https://sourceforge.net/p/abook/feature-requests/13/
https://sourceforge.net/p/abook/mailman/abook-devel/?viewmonth=202011
but these was not merged so far.
Hi @gibboris , thanks for your quick reply.
I would think, that the effect of having to use the abook application with the
--datafile
argument, each time the application is called (from within mutt and from the command line) makes it necessary to always remember that location each time. But when the--datafile
flag could be set within abook's configuration file (default is~/.abook/abookrc
) I could set it once there and forget about it in the future.As far as I have seen, there is no way to set
--datafile
within the rc file, right?Could this option be added to the rc file, instead of identifying and evaluating symbolic links?
Thanks.