lei-mail-formats(5)

LEI-MAIL-FORMATS(5) public-inbox user manual LEI-MAIL-FORMATS(5)

NAME

lei-mail-formats - description of mail formats supported by lei

DESCRIPTION

lei-q(1) supports writing to several existing mail formats for interoperability with existing mail user agents (MUA); below is an overview of them to help users choose.

Maildir

The default output format when given a filesystem path, it supports parallel read-write access. Performance is acceptable for smaller directories, but degrades as mailboxes get larger. Speed and scalability are limited by kernel and filesystem performance due to the use of small files and large number of syscalls.

See also: <https://cr.yp.to/proto/maildir.html> and <https://wiki2.dovecot.org/MailboxFormat/Maildir>

Mbox family

The mbox family consists of several incompatible formats. Locking for parallel access is supported, but may not be compatible across tools. With compression (e.g. gzip(1)), they require the least amount of space while offering good read-only performance.

Keyword updates ("Status:" and/or "X-Status:" headers) generally require rewriting the entire mbox.

See also: <https://www.loc.gov/preservation/digital/formats/fdd/fdd000383.shtml>, mbox(5)

mboxo

The traditional BSD format. It quotes "From " to ">From ", but lines already beginning with ">From " do not get quoted, thus automatic reversibility is not guaranteed. MUAs which favor "mboxcl" or "mboxcl2" may convert these automatically to their preferred format.

Truncation is undetectable unless compressed with gzip or similar.

mboxrd

An evolution of "mboxo", but quotes "From " lines prefixed with any number of ">" characters and is thus fully reversible.

This format is emitted by PublicInbox::WWW(3pm) with gzip. It is supported by git-am(1) since git 2.10.

As with uncompressed "mboxo", uncompressed mboxrd are vulnerable to undetectable truncation.

It gracefully degrades to being treated as "mboxo" by MUAs unaware of the format as excessive ">From " quoting is recognizable to humans.

mboxcl

"mboxo" with a "Content-Length:" header, "From " lines remain quoted to retain readability with "mboxo" and "mboxrd" MUAs. However, it is easy to corrupt these files when using tools which are not aware of "Content-Length:" and write out updates as "mboxo".

mutt(1) will convert "mboxo" and "mboxrd" to mboxcl upon opening.

See also: <https://www.jwz.org/doc/content-length.html>

mboxcl2

Like "mboxcl", but without "From " any quoting. It is wholly incompatible with MUAs which only handle "mboxo" and/or "mboxrd". This is format is generated by mutt(1) when writing to a new mbox.

MH

Not yet supported, locking semantics (or lack thereof) appear to make it unsuitable for parallel access.

IMAP

Depending on the IMAP server software and configuration, IMAP servers may use any (or combination) of the aforementioned formats or a non-standard database backend.

COPYRIGHT

Copyright 2021 all contributors <mailto:meta@public-inbox.org>

License: AGPL-3.0+ <http://www.gnu.org/licenses/agpl-3.0.txt>

SEE ALSO

lei(1), lei-q(1), lei-convert(1), lei-overview(7)

1993-10-02 public-inbox.git