procmail
[Top] [All Lists]

Re: Me again...

1998-10-19 23:21:16
On Mon, 19 Oct 1998 15:00:18 -0700 (PDT), "Stephen C. Hill"
<steveh(_at_)nugrange(_dot_)vip(_dot_)best(_dot_)com> wrote:
anything that has a header line that starts out "TO:{space}{followed by
any characters, which are then followed by 
...}<discuss(_at_)nowhere(_dot_)com >",
should be written to the file "nowhere".  Since email is usually written
"To: xxx", most times your recipe will miss it, due to the upper case O.

No, unless there's a D flag, Procmail doesn't care about character case.
Assuming there's a space after the colon is stupid in theory, but
doesn't matter much in practice. And of course, if it's a "real"
mailing list, it will probably have more reliable headers than To: and
Cc: you can look at. 
  (This list, for example, always has a Resent-From: but I actually
match on the From_ pseudoheader when determining what's from the
Procmail list. That means messages which are Cc:ed to myself, for
example, but also sent to the list, arrive in two copies, where the
personal one goes to my personal inbox and the list copy goes to the
list's spool.)

As you can see by the regexp above, ^TO looks for To: or Cc: or Bcc:, as
well as other headers.  The single line should be sufficent.

And of course, as usual, you should probably use ^TO_ instead of ^TO
if your Procmail is a recent version.

/* era */

-- 
Bot Bait: It shouldn't even matter whether  (`')  Just  (`')  http://www.iki
I am a resident of the State of Washington   \/ Married! \/   .fi/~era/

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