procmail
[Top] [All Lists]

Re: Problem with matching whole word

2001-09-06 04:31:18
Hello, 

I use procmail to filter incoming mail to my server with this
code: 

:0

* EXT2 ?? lukas.futera
|/usr/sbin/sendmail futera_cz_lukas(_at_)my(_dot_)server(_dot_)cz

Btw, I suspect it will do nasty things if you really have that blank line in
your recipe.

May be, but this is filled by qmail, so it should be OK.

EXT2 is a variable filled by qmail - in which is the recipient from the
mail like EXT2="lukas.futera".

But i have a problem with matching the recipient, bcaus if there is for
example onle "futera" or "lukas" it matches "lukas.futera" too. I tried to
use ^^and regexp and things like that - but i didn't ucceed. 

I need the EXACT match with these two strings (one in variable and one in
procmail script) 

It seems to me that if you quote the dot in your recipe, your
problem might go away.  '.' in procmailese means any single
character, and in this case, a space seems to be matching.

Try

      * EXT2 ?? lukas\.futera

Thank you for answering but This is not exactly what I was talking about. I 
know this problem. But
there is still the problem, that "lukas" or "futera" or "fut" still
matches this rule. 

I saw in manual something like if I enclose the string in ^^ ^^ .. it will
help. 

* EXT2 ^^lukas\.futera^^ 

but it didn't work for me :-(. So I am looking for solution.

S pozdravem Lukas Futera
--
<...> Nethost s.r.o. (futik(_at_)nethost(_dot_)cz)

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

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