On Thu, Apr 05, 2001 at 12:21:05PM +1000, Sonam Chauhan wrote:
> I want to seperate messages stored in different mbox-format files into 
> distinct files containing one email each, with filenames of the type:
> '20010101-1201-random_number.msg' (for a message sent on 12:01 Jan 1, 2001). 
> 
> I get the feeling with all these mail manipulation programs out there, 
> there is likely to be one that understands a RFC 822 Date: header 
> and converts the date to a simpler data structure.
> Q 1.) Can someone suggest such a program ?

Perhaps formail(1)?  I'm not really sure, but I *think* it could
probably help with this... anyway, it's part of the procmail package on
debian.

Otherwise, Python has a rfc822 module :)

> I then intend sorting these messages by date (i.e. by filename) and 
> feeding them one by one to hypermail (Hypermail requires mbox files 
> to be date sorted, otherwise it gets mixed up in date sorting)
> Q 2.) Is there a better approach? 

I imagine there probably is, but I'm not sure what it is.  And besides,
I use mutt :)

-Andrew.

-- 
SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/
More Info: http://slug.org.au/lists/listinfo/slug

Reply via email to