procmail
[Top] [All Lists]

Re: question Re: 'Simple recipe question' answer

1996-08-27 12:28:54
Brandon Zylstra inquired:
can you explain why he shouldn't use the .* after TO?  i don't understand
how it would work without that.

  -brandon

On Tue, 27 Aug 1996, Guy Geens wrote:
On Tue, 27 Aug 1996, Morrison, Peter wrote:
I tried:
* ^TO.*p[^\ \t\n,;](_at_)domain\(_dot_)name

What Peter wanted was destinations starting with 'p'.  The .*
will match any *containing* a 'p', such as "tulip(_at_)domain(_dot_)name".

"^TO" and "^TO_" are sort of "magic" -- they don't obey intuitive
rules for "tokens" that we would normally expect.  As was pointed
out to me about a month ago, you can always write:
        * ^TO()p[^\ \t\n,;]*(_at_)domain\(_dot_)name
if it "feels" better. (I've inserted the missing * after the bracket
as well, which someone else noted.)

Does anyone know if that first "\" is necessary (to escape a space)?
And isn't that \n useless since the header is processed with
newlines removed?

Cheers,
Stan Ryckman (stanr(_at_)tiac(_dot_)net)

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