procmail
[Top] [All Lists]

Re: subject processing

1997-07-05 03:35:00
On Fri, 4 Jul 1997 21:52:01 +0300 (EET DST), I wrote:
On Fri, 4 Jul 97 11:31 EDT, 
process(_at_)qz(_dot_)little-neck(_dot_)ny(_dot_)us 
(Eli the Bearded) wrote:
era eriksson <era(_at_)iki(_dot_)fi> wrote:
:0fhw
* ^\/Subject:[     ]*((re|fw|sv|betr|antw)( ?[[][0-9]+])?[-:>][    ]*)+
| ... some suitable program which does essentially \
  sed "s/^$MATCH/Subject: /"
That is not quite what he wanted because he wished ones with an Re:
in the subject to continue to have an Re: in the subject. And sed
will not find a match when trying "^Subject: Re[4]: Re: " against
"Subject: Re[4]: Re: ". [] are metacharacters remember.

Much to my surprise, I find that there is actually a simple fix in
3.11pre4 and newer which I had not noticed: $\VAR will quote the
variable with magical characters escaped. However, it seems that this
helpful substitution will add a set of empty parens at the beginning
of the interpolated value. Duh. How do we solve that? 

/* era */

-- 
Defin-i-t-e-ly. Sep-a-r-a-te. Gram-m-a-r.  <http://www.iki.fi/~era/>
 * Enjoy receiving spam? Register at <http://www.iki.fi/~era/spam.html>

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