library config API
David Bremner
david at tethera.net
Sat Jan 23 06:59:53 PST 2016
This is the third revision of this series, and I think the first two
patches are ready for serious review.
Some things to think about with respect to the CLI patches
- Should we include a "version" line at the top of the dump? Currently this is unused, but that
depends on the format being auto detectable?
- Should config info be included by default in the dump output?
- Should we restore config info by default?
- How about the usual bikeshedding about argument names? I'm loath to
spend time on docs until after this.
I guess a global question is what do we need this API / feature for. I
can think of three things so far
- tag aliases [1]
- making the location of the mail tree configurable (i.e. allowing
mailtree and database to live in different places).
- Some things like excludes and maildir synchonization are natural to
have in common between all clients.
A natural question is why not provide a library API to access
.notmuch-config? Having a plain text representation of the
configuration (without the extra step of dumping it) is obviously
attractive, but
- We would need to build some locking / synchronization to prevent
various clients and interactive text editors from stomping on each
other. This we have for free by using xapian metadata.
- We'd also have to provide our own key/value datastructure.
- At least for tag aliases, I think there is a second argument that
this information part of the users tagging state, and should be
backed up as part of the normal dump / restore process.
[1]: id:87mvsd7cxr.fsf at zancas.localnet
More information about the notmuch
mailing list