[prev in list] [next in list] [prev in thread] [next in thread] 

List:       procmail
Subject:    Re: forward blank or empty subjects
From:       PSE-L () mail ! professional ! org (Professional Software Engineering)
Date:       2001-01-31 17:52:21
[Download RAW message or body]

At 09:43 2001-01-31 -0200, Joćo Paulo Andrade did say:

>:0h
>* ^Subject:[ ]*$
>!patric_fernandes@localdomain.com.br

Note that the regexp you're using here could also catch NO SPACE as well - use:

* ^Subject: $

If you truly want to capture a SINGLE (brackets or parens should work fine 
too, but since you don't have OR conditions or character classes, they're 
superfluous).

* ^Subject:[ ]+$

One or more spaces.

* ^Subject:[ ]?$

Zero or one space (which looks appropriate to your next regexp).

>:0 fw
>* 1^0 ^Subject:([ ]$|$)
>!patric_fernandes@localdomain.com.br

Please evaluate the reasoning behind your selection of flags on this 
rule.  Check the procmail manpages for the function of the flags you are using.

And, as per Collins sound recommendation, turn on verbose logging and 
examine the logfile - you'll learn a lot just from that, especially from 
the error messages you're probably getting from the latter rule.


I think what you probably want is:

:0h
* ^Subject:[ ]?$
! patric_fernandes@localdomain.com.br

Which should catch messages which contain a Subject header which consists 
of either a single space, or none at all, then end of line.

Of course, perhaps you just want messages which have blank (but _existing_) 
Subjects, in which case, there may be more than one space, or there may be 
tabs in there.  If so, use:

* ^Subject:[    ]*$

(brackets contain space and tab).


Didn't we go over this very same stuff just a little over a week ago?

---
  Sean B. Straw / Professional Software Engineering

  Procmail disclaimer: <http://www.professional.org/procmail/disclaimer.html>
  Please DO NOT carbon me on list replies.  I'll get my copy from the list.

_______________________________________________
procmail mailing list
procmail@lists.RWTH-Aachen.DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic