=head1 NAME lei-mail-formats - description of mail formats supported by lei =head1 DESCRIPTION L 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. =head1 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: L and L =head1 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. L), they require the least amount of space while offering good read-only performance. Keyword updates (C and/or C headers) generally require rewriting the entire mbox. See also: L, L =head2 mboxo The traditional BSD format. It quotes C to CFrom >, but lines already beginning with CFrom > do not get quoted, thus automatic reversibility is not guaranteed. MUAs which favor L or L may convert these automatically to their preferred format. Truncation is undetectable unless compressed with gzip or similar. =head2 mboxrd An evolution of L, but quotes C lines prefixed with any number of C> characters and is thus fully reversible. This format is emitted by L with gzip. Since git 2.10, C reads this format. C and C can also generate this format with the C<--pretty=mboxrd> switch. As with uncompressed L, uncompressed mboxrd are vulnerable to undetectable truncation. It gracefully degrades to being treated as L by MUAs unaware of the format as excessive CFrom > quoting is recognizable to humans. =head2 mboxcl L with a C header, C lines remain quoted to retain readability with L and L MUAs. However, it is easy to corrupt these files when using tools which are not aware of C and write out updates as L. L will convert L and L to mboxcl upon opening. See also: L =head2 mboxcl2 Like L, but without C any quoting. It is wholly incompatible with MUAs which only handle L and/or L. This is format is generated by L when writing to a new mbox. =head1 MH Not yet supported, locking semantics (or lack thereof) appear to make it unsuitable for parallel access. It is widely-supported by a variety of MUAs and mailing list managers, however. =head1 MMDF Not yet supported, and it's unclear if current usage/support makes it worth supporting. =head1 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. =head1 eml A single raw message file. C is not an output format for lei, but accepted by as an C<--input-format> (C<-F>) for read-only commands such as L and L. Since C is the suffix for the C MIME type (according to the C file), lei will infer the type based on the C<.eml> suffix if C<--input-format> is unspecified C<.patch>-suffixed files generated by L (without C<--stdout>) are C files with the addition of an mbox C header. L removes C lines to treat them as C when reading these for compatibility with C and similar tools. =head1 COPYRIGHT Copyright 2021 all contributors L License: AGPL-3.0+ L =head1 SEE ALSO L, L, L, L