Marc Rackett (ETLMCRT XB/VAC) wrote
I was wondering if any of you procmail/regular expression
gurus could explain the following syntax:
!^Subject: send file .*[/.]\.
^ from here
. means match any character except return
* means match the previous expression 0 or more times
.* means many any number of characters execpt return
[/.] means match if the next character is a '/' or a '.'
\. means literally match a period. The '\' escapes the special
meaning of '.' that regular expressions usually take.
So, the above expression would match:
Subject: send file anything here/.
and
Subject: send file more here..
but not
Subject: send file something here.
or
Subject: send file ack /
or
Subject: send file test
Hope this helps.
Steve
--
-----------------------------------------------------------
Steven Jorgensen steve(_at_)khoral(_dot_)com
steve(_at_)haunt(_dot_)com
------------------------------+----------------------------
Khoral Research Inc. | PHONE: (505) 837-6500
6001 Indian School, Suite 200 | FAX: (505) 881-3842
Albuquerque, NM 87110 | URL: http://www.khoral.com/
-----------------------------------------------------------