Re: Using mutt for MMDF to mbox conversion -- problem!
* René Clerc <rene@xxxxxxxx> [04-02-04 14:37]:
>
> However, mutt -f <new_folder> gives me back less messages! Inspection
> learns that some messages are concatenated; apparently, some From_
> headers were not written. I find this very strange (because on MMDF,
> mutt was able to seperately identify the messages.
>
> Does this sound familiar to anyone? If this is a mutt problem, I'll be
> glad to help track down the problem (provided, of course, that someone
> gives me a hint on how to convert my MMDF folders..) ;-)
I do not know that it is a mutt problem but I recall that procmail will
do what you need, ie:
man procmail:
-f fromwhom
Causes procmail to regenerate the leading From ' line with
fromwhom as the sender (instead of -f one could use the
alternate and obsolete -r). If fromwhom consists merely of a
single -', then procmail will only update the timestamp on
the From ' line (if present, if not, it will generate a new
one).
Pipe your suspect mail folder bach thru procmail and, perhaps
include the following recipe:
# Work around procmail bug: any output on stderr will cause the "F" in
# "From" to be dropped. This will re-add it.
:0
* ^^rom[ ]
{
LOG="*** Dropped F off From_ header! Fixing up. "
:0 fhw
| sed -e '1s/^/F/'
}
formail -ds procmail -f - -m sandbox.including.'from'.recipe.rc < mbox.file
warning, usual disclaimers, command-line untested.
gud luk,
--
Patrick Shanahan Registered Linux User #207535
http://wahoo.no-ip.org @ http://counter.li.org
HOG # US1244711