procmail
[Top] [All Lists]

Re: forwarding

2001-04-08 15:30:01
On Sun, Apr 08, 2001 at 10:51:47PM +0200, Johannes Zellner wrote:
Hi,

I've a simple task, which I cannot solve.
I'd like to forward all mails which come NOT from me AND are NOT
directed to the specific computer where procmail runs. I tried:

    DEFAULT = /var/spool/mail/joze

    :0:
    * !^From:(_dot_)*johannes(_at_)zellner(_dot_)org
    * !^To:(_dot_)*joze(_at_)krispc6(_dot_)physik(_dot_)uni-karlsruhe(_dot_)de
    !johannes(_at_)zellner(_dot_)org

why does this not work ?

I guess that I'm a little unclear... you want mail that is
both from you AND directed to joze(_at_)krispc6 to stay put, and
for everything else to be forwarded, right? If that's the
case then you want to OR the two conditions together, like
so:

     :0:
     * 1^0 !^From:(_dot_)*johannes(_at_)zellner(_dot_)org
     * 1^0 
!^To:(_dot_)*joze(_at_)krispc6(_dot_)physik(_dot_)uni-karlsruhe(_dot_)de
     !johannes(_at_)zellner(_dot_)org

In this way mail that is either not from you or not to
joze(_at_)krispc6 will be forwarded. Only mail that is both from
you and addressed to joze(_at_)krispc6 will get through.

-- 
John Patton                      patton66(_at_)home(_dot_)com
Get my GnuPG public key: finger john(_at_)24(_dot_)22(_dot_)215(_dot_)225

"The mind, once stretched by an empowering idea, can never  
fully shrink to its original dimensions." - Unknown         
_______________________________________________
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>