Can mutt be persuaded to use a sensible maildir hierarchy?
Cameron Simpson
cs at cskk.id.au
Wed Sep 23 20:50:03 UTC 2020
On 23Sep2020 14:58, Kurt Hackenberg <kh at panix.com> wrote:
>On 2020-09-23 04:07, Chris Green wrote:
>
>>I think I might try that second idea, I can run mb2md (as you say)
>>2354 times and get the layout I want. Then I can try mutt on it and
>>see if it's practical.
>
>
>Does mb2md convert message attributes? (Message has been read, message
>has been replied to, etc.)
Easy to test though. And easy to patch mb2md if lacking.
>In mbox files, I believe Mutt stores that stuff in the common but
>non-standard headers Status:, X-Status:, and X-Label:. Maildir instead
>encodes much of that in message pathnames. Basic maildir has no way to
>encode labels/keywords, but Dovecot has added its own mechanism for
>that. I don't know how Mutt stores labels in maildir.
The label %Y displays comes from X-Label. I use it extensively.
One can also remember that you can convert mailboxes using mutt, in
which case you're assures that the results will be mutt compatible :-)
Here's a line from the guts of my mboxify script, which I use to bulk
convert Maildir to mbox (I keep my archive folders as mbox, more
compact):
mutt -n -F /dev/null -f "$mailbox" -e "set sort=mailbox-order; set confirmappend=no; set delete=yes; push '<tag-pattern>.<enter><tag-prefix><save-message>$mailboxtmp<enter><sync-mailbox><exit>'"
where $mailbox is the source mail folder and $mailboxtmp is a scratch
mbox folder (intially just an empty file of course), which gets renamed
if the mutt succeeds.
Cheers,
Cameron Simpson <cs at cskk.id.au>
More information about the Mutt-users
mailing list