Bug 105375 - Import Mailman message archives
Summary: Import Mailman message archives
Status: RESOLVED FIXED
Alias: None
Product: kmail
Classification: Unmaintained
Component: kmailcvt (show other bugs)
Version: unspecified
Platform: openSUSE Linux
: NOR wishlist
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-05-09 21:50 UTC by Tristan Miller
Modified: 2009-03-19 00:30 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
A sample GNU Mailman archive (6.49 KB, application/x-bzip2)
2005-05-09 23:07 UTC, Tristan Miller
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tristan Miller 2005-05-09 21:50:43 UTC
Version:            (using KDE KDE 3.4.0)
Installed from:    SuSE RPMs

Please add a filter for the Tools->Import Messages command which can process message archives from Mailman, the GNU Mailing List Manager <http://www.gnu.org/software/mailman/>.  Mailman allows list subscribers to download archives of messages in a format very similar to Unix mbox.  Differences include trivial spam-munging of e-mail addresses ("foo at example.com" format).  I think the date format might also be slightly different, because KMail's existing mbox import filter lists "Unknown" for the date of all imported messages.
Comment 1 Danny Kukawka 2005-05-09 22:12:31 UTC
The mbox import filter also work with mailman archive. If KMail display the date as unknown the date format is not rfc-compliant! For me it´s not wanted or the job of kmailcvt to parse, check and change the date format of a imported mail.

Can you post a link to a mailarchiv with this problem?
Comment 2 Tristan Miller 2005-05-09 23:06:12 UTC
Yes, the date format might not by RFC-compliant, but if so that's Mailman's decision.  No one is saying you have to bend over backwards to make kmailcvt compatible with their nonstandard formats; this is just a wishlist suggestion!

Anyway, I'm attaching an example of a Mailman archive that the existing mbox filter doesn't import correctly.
Comment 3 Tristan Miller 2005-05-09 23:07:00 UTC
Created attachment 10969 [details]
A sample GNU Mailman archive
Comment 4 Tristan Miller 2005-07-28 15:48:37 UTC
The following sed script converts the mailman archives to a format usable by kmailcvt's mbox import filter.  It demunges e-mail addresses, adds a "To:" header, and fixes the date format.

sed -e 's/^From\(:\? .*\) at /From\1@/;s/^\(From: .*\)/\1\nTo: pracjourn-prod@tug.org/;s/^Date: \(...\) \(...\) \+\([0-9]\+\) \(..:..:..\) \(....\)/Date: \1, \3 \2 \5 \4 GMT/'

Two caveats:

1) The mailman Date: field doesn't include a timezone, so I'm not sure if it's supposed to be GMT or the local time of the mail server.
2) The sed script doesn't differentiate between mail headers and mail bodies, so any lines beginning with "From:" or "Date:" in the body are also processed.
Comment 5 Danny Kukawka 2006-08-31 13:21:35 UTC
Tested with the attached archive and KMail 1.9.3/Kontact 1.2.3/KDE 3.5.4 and all work correct now.