implement exporting of all mailboxes/messages as zip/tgz of mbox/maildir

This commit is contained in:
Mechiel Lukkien
2023-02-13 18:04:05 +01:00
parent ad51ffc365
commit 3de6642b3a
6 changed files with 547 additions and 7 deletions

6
doc.go
View File

@ -263,7 +263,8 @@ Export one or all mailboxes from an account in maildir format.
Export bypasses a running mox instance. It opens the account mailbox/message
database file directly. This may block if a running mox instance also has the
database open, e.g. for IMAP connections.
database open, e.g. for IMAP connections. To export from a running instance, use
the accounts web page.
usage: mox export maildir dst-path account-path [mailbox]
@ -275,7 +276,8 @@ Using mbox is not recommended. Maildir is a better format.
Export bypasses a running mox instance. It opens the account mailbox/message
database file directly. This may block if a running mox instance also has the
database open, e.g. for IMAP connections.
database open, e.g. for IMAP connections. To export from a running instance, use
the accounts web page.
For mbox export, we use "mboxrd" where message lines starting with the magic
"From " string are escaped by prepending a >. We escape all ">*From ",