[notmuch] Mailstore abstraction & maildir synchronization
Michal Sojka
sojkam1 at fel.cvut.cz
Fri Mar 26 15:08:58 PDT 2010
On Wed, 24 Mar 2010, Stewart Smith wrote:
> On Thu, 18 Mar 2010 16:39:36 +0100, Michal Sojka <sojkam1 at fel.cvut.cz> wrote:
> > - Only file-based storage is suported. Notmuch access the files
> > directly, and not via the mailstore interface.
>
> It'll be great when this is fixed... should be trivial to add a git
> backend then.
Yes, it seems to be quite trivial. I'll probably look at this tomorrow.
>
> (i have in no way been looking at tags in git though... doesn't really
> interest me and git aint a database)
My aim is only to store tags in git for the purpose of synchronization.
I'm not interested in searching by tags. The idea is that for every
message there will be an additional blob containging tags - one tag per
line.
>
> > - (maildir) Viewing/storing of attachments of unread messages doesn't
> > work. The reason is that when you view the message it its unread tag
> > is removed which leads to rename of the file, but Emacs still uses
> > the original name to access the attachment.
>
> What about migrating from a maildir that's turned into notmuch back to
> this maildir backend? What will be authoritive: maildir or notmuch
> database?
Maildir is authoritative, but only for tags corresponding to maildir
flags. Other tags are never touched by this code. See also the updated
commit message in "[PATCH v2 3/4] Add maildir-based mailstore".
If you want to sync your maildirs with the databse the following should
work (not tested):
notmuch dump > dump
cat <<EOF >> ~/.notmuch-config
[mailstore]
type=maildir
EOF
notmuch restore dump
--Michal
More information about the notmuch
mailing list