procmail
[Top] [All Lists]

Re: Removing [somelist] from subject lines

2001-01-21 12:38:18
"Mike A. Harris" <mharris(_at_)opensourceadvocate(_dot_)org> writes:

I want to integrate the recipe you provide above into this rule,
so that the filter is only applied to this specific list.

I see you've gotten help from more knowledgable posters than I, so
you're on your way.

Maybe someone can correct this if wrong but I believe if you put the
lock thing in the recipe (:), drop the `header only, drop filter and
rewrite the script so that it effects only header area, you could have
awk deliver to the proper group for you.

It seems simpler to me to do it this way. But there may be unforeseen
problems with it.

    :0:
    * ^Subject:.*\[lula\]
    | awk '\
 /^From / {a = 1}\
 /^$/ {a = 0}/^Subject: / && a==1 {gsub(/\[lula\] /,"");print $0;next}\
 {print}'  >> PROPER_GROUP

I've done this without problems, but have only a simple ~/.procmailrc

You'll need to take care with the awk script that procmail sees the
line continuations correctly. (Note the space at beginning of line
following each "\")
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail