[plt-scheme] mail-parse.ss

From: Stephen De Gabrielle (spdegabrielle at gmail.com)
Date: Wed Jun 11 10:41:36 EDT 2008

Hi,

I've been fiddling with the mail-parse.ss library. (planet
"mail-parse.ss" ("mburns" "mail-parse.plt" 1 0))

I've  version-4-ised it and changed a regular expression to handle
'eml' and 'mail' files (ala thunderbird and outlook express):
;; Is this line the start of  a new email?
(define (new-email? line)
 (pregexp-match
"^(?mi:From|To|Envelope.*|Received|Return-Path|Date|Subject|Content\\-.*|MIME-Version|Forwarded|Message.*|From\\s)"
line))

I stole the regex from the Greenstone Digital Library:
http://trac.greenstone.org/browser/gsdl/trunk/perllib/plugins/EmailPlugin.pm
 (html page of the code via a trac instance)

I haven't updated it on planet, because it's not my library. (I've
email the author, but got no response)

Should I update it on planet myself? Is it appropriate without
permission. (the author asserts copyright, but I don't know what
license  LGPL perhaps?)

Cheers,

Stephen

--
Stephen De Gabrielle
s.degabrielle at cs.ucl.ac.uk
Telephone +44 (0)20 7679 0693 (x30693)
Mobile                  079 851 890 45
Project: Making Sense of Information (MaSI)
http://www.uclic.ucl.ac.uk/annb/MaSI.html

UCL Interaction Centre
MPEB 8th floor
University College London
Gower Street
London WC1E 6BT



-- 
Cheers,

Stephen

--
Stephen De Gabrielle
s.degabrielle at cs.ucl.ac.uk
Telephone +44 (0)20 7679 0693 (x30693)
Mobile 079 851 890 45
Project: Making Sense of Information (MaSI)
http://www.uclic.ucl.ac.uk/annb/MaSI.html

UCL Interaction Centre
MPEB 8th floor
University College London
Gower Street
London WC1E 6BT


Posted on the users mailing list.