procmail
[Top] [All Lists]

Question on $MATCH

2002-08-23 23:39:16
Hi,
Problem description.

I need to filter mails based on the "Subject:". The subject can contain
varios lines as below:
1. Subject: [paper] This is a test paper.
2. Subject: [url] this is a test URL
3. Subject: [thought] this is a test thought.

Now when procmail receives this email, I need a receipe which does the
following..

It will pasrse the header for the "Subject" lines and find out what the term
in the braket is.. for e.g. 'paper' or 'url' or 'thought'

It then saves the message to the appropriate folder..

for e.g. the following perl-like receipe is what i want..

:0:
* ^Subject:.*\[(.*)\](.*)
IN-$1

(I know there is no $1 in procmail.. but i wanted an equivalent condition
that can do the same thing.. )
Any help is greatly appreciated.
Thanks
Shashank




_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>