procmail
[Top] [All Lists]

Re: FOLLOWUP >> Re: Matching 6 lines in the body, in order

1998-06-14 11:01:30
Timothy Luoma continued,

| This is what I have settled on, but I want to make SURE that this will ONLY
| match when the first five lines are *left justified* AND are the *first*
| lines of the email message after *one* blank line
| 
| :0fhw
| * B ?? ^^($)*Authenticated sender is.*$\
|             Subject:.*$\
|             Mime-Version: 1\.0$\
|             Content-Type: text/plain; charset="us-ascii"$\
|             Content-Transfer-Encoding: 7bit$
| * B ?? ^EMAIL MARKETING WORKS
| * B ?? ^Bull's Eye Gold
| | formail -A"X-SpamChecker: Bulls Eye Gold"

That will allow any number of blank lines at the start of the body before
"Authenticated Sender is".  The lines must be the first (non-blank) ones in
the body and they must be left-justified.

If by "*one* blank line," Timothy, you mean the blank line that separates
the head from the body, take out the "($)*".  If you mean one blank line
in the body proper after the one that separates the head from the body,
take out the asterisk from "($)*" but leave "($)".  From the rest of your
text, I gather you want the former.

Another thing you can do is to put the `B' flag on the recipe; then you
won't need "B ??" on every condition.

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