[H-GEN] archiving old e-mail

Ben Fowler b1.fowler at student.qut.edu.au
Tue Jan 11 03:03:35 EST 2000


[ Humbug *General* list - semi-serious discussions about Humbug and ]
[ Unix-related topics.  Please observe the list's charter.          ]

Dear All,

I recently got the idea of sorting out and archiving my collection of old
e-mail accumulated over the last 3 years, and this weekend, I took it on,
and came up with a solution using formail, procmail and hypermail, and
gave me nice indexed HTML mail archives.

My first challenge was sorting the 30 meg pile of unsorted mail.  After
canvassing suggestions from some HUMBUGgers, I settled on procmail but
quickly discovered that it wasn't designed for interactive use (i.e. you
can't just dump a mail folder in one end and get sorted mailfolders out
the other, you need it run off an MTA or a .forward file).

My solution was this.

1)  I wrote a .procmailrc to categorise my mail into folders for each
     mailing list or source that I wanted to create an archive for.
2)  I got my mail sorted like so:

 $ cat ~/unsorted-mail/* | formail -s procmail

    ...such that all the mail got sorted lands in nice folders under
       ~/Mail.  This command takes a while to execute, since it invokes
       procmail for every single piece of mail.

After that, I configured hypermail, and write a 3-line shell script to
generate the HTMLised mail archives.  One minor issue:  make sure that
mails and matching replies are put into the same archives, otherwise
hypermail's message threading "breaks" and the resulting HTML archives
look weird.

I hope that someone finds this vaugely interesting and useful.

- warmest regards,

Ben.

--
 Ben Fowler,  3rd-year BInfTech, Queensland Univerity of Technology.
  e-mail:       ben.fowler at humbug.org.au  b1.fowler at student.qut.edu.au 
  vanity page:  http://azure.humbug.org.au/~zuul/ 
 "If I have seen further, it is by standing on the shoulders of Giants"
                                                -- Isaac Newton


--
* This is list (humbug) general handled by majordomo at lists.humbug.org.au .
* Postings to this list are only accepted from subscribed addresses of
* lists 'general' or 'general-post'.



More information about the General mailing list