Maildir format
Created on 2023-02-28T01:29:45-06:00
Each mail message is encoded as:
- a header section,
- a blank line,
- the body section
However unlike mbox each message has its own file in a directory.
A whole mailbox has three directories within itself: new, cur, and tmp.
tmp: when storing new messages they are written here, flushed, then atomically moved to 'new.'
new: messages deposited to a mailbox but not acknowledged by the mail client belong here.
cur: messages that mail software has acknowledged as newly arrived are moved to this directory. mail lives here until the user moves or deletes it.
Atomic moves are typically done with `rename` or by hardlinking then unlinking the original.