procmail
[Top] [All Lists]

Re: exact match

1997-01-13 14:00:54
On 13 Jan 97 06:59:46 EST, Costa <100270(_dot_)3700(_at_)CompuServe(_dot_)COM> 
wrote:
I found following statement in a readme file:

What kind of a readme was that? :^/

:0
* ^TO.*info
! user1(_at_)me(_dot_)com

The ^TO macro is special -- don't use a wildcard after it. You might
also want to check in the manual whether you'd actually prefer the
^TO_ macro instead (if your Procmail is new enough). 

This should do what you want: 

  :0
  * ^TO_info@
  ! user1(_at_)me(_dot_)com

Generally speaking, the \< and \> regular expression operators would
be worth looking at. 

If you don't really want ^TO (which matches To: but also Cc:,
Resent-To:, etc etc ad naus.), write it with a lowercase o and a colon
after it -- in this case, since you're not using a special macro
anymore, you want the wildcard in there again. 

  :0
  * ^To:.*\<info@
  ! user1(_at_)me(_dot_)com

Hope this helps,

/* era */

-- 
See <http://www.ling.helsinki.fi/~reriksso/> for mantra, disclaimer, etc.
* If you enjoy getting spam, I'd appreciate it if you'd register yourself
  at the following URL:  <http://www.ling.helsinki.fi/~reriksso/spam.html>

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