Travel

Categories

Simple .procmailrc format

In other words, your recipe is being used, but the pattern you give
does not match the incoming mail.  I think you are hoping that “^FROM”
is a special procmail expression, like “^TO”, “^FROM_DAEMON”, and
“^FROM_MAILER”;  unfortunately, this is not the case.  What you meant
is probably:

* ^From:.*jane

However, that would catch mail from “joe@janet.com”, which is
^^^^
probably not quite what you want either.  Perhaps

* ^From:.*\<jane@cs\.concordia\.ca\>

would fit the bill.

What it means is:

*                       Start pattern.

^                       Match at beginning of a line; i.e. the next
word or symbol must occur at the start of
the line.

From:                   Match the word “from” (upper or lowercase
or mixed), followed by a colon.  That’s the
“From:” header.

.*                      Match anything (zero or more “wildcard”
characters);  this will eat any “comments”,
such as the person’s full name, etc., and
possibly the space after the “From:”, though
the last non-alpha, non-digit character
before the start of the thing you want to
match will be eaten by…

\<                      Match a “word delimiter” character
(anything except a letter, digit, or
underscore) or a newline — this avoids
matching on, say, “jbjane@cs…”.

jane@cs\.concordia\.ca  Match your target address, where dots are
*not* wildcards but match real dots.  You
don’t *have* to escape the dots, but if you
don’t, you might accidentally match
“jane@csxconcordiaxca”, which is not what
you want.

\>                      Now match a word delimiter or a newline
again; this avoids matching the unlikely
“jane@cs.concordia.cam.org”, for example.

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

  

  

  

WP-Highlight