astroid icon indicating copy to clipboard operation
astroid copied to clipboard

proper Maildir handling

Open jorsn opened this issue 4 years ago • 1 comments

According to https:../wiki/Configuration-Reference (and config.cc), astroid does not use Maildir properly: E.g., thou shalt NEVER inject a message into /cur/! A message shall be written to /tmp, then moved to /new. When it is first touched by any program, it shall be moved to /cur.

By default, astroid writes sent messages to $maildir/sent/cur/ (accounts.[accountname].save_sent_to) and drafts to $maildir/drafts (save_drafts_to), which does clearly not conform with any Maildir spec [1, 2, 3, 4].

If astroid needs to support different Mailbox formats, IMHO it should either implement them correctly, or build upon something like GNU mailutils, which has a mailbox abstraction over POP, IMAP, SMTP and sendmail.

At the moment it seems like astroid just uses file system folders, agnostic of the mailbox format.

jorsn avatar May 16 '20 23:05 jorsn

I agree, messages should be written to tmp then moved to cur/ or new/ depending on the flags/tags so that maildir flags are supported. Astroid does not really know about maildir. It only supports mail files and notmuch, which is not tied to maildir strictly. Mailbox is not supported. POP/IMAP/SMTP is not directly supported in astroid, but through notmuch and other tools.

gauteh avatar May 18 '20 09:05 gauteh