procmail
[Top] [All Lists]

Re: Like an Alias...

2002-03-01 07:05:54
From: "Fred" <mfleao(_at_)planae(_dot_)com(_dot_)br>


Subject: Like an Alias...

"Touched for the very first time"?


:0
*    ^From:(_dot_)*(_at_)mydomain(_dot_)com*
*    ^To:(_dot_)*linux(_at_)mydomain(_dot_)com*
{
    :0
    ! linux-addr(_at_)mydomain(_dot_)com
}
----- End

but... didn't work...
anyone could help me?!

First, you don't want or need the asterisks at the end of
your expression.  (Even if you did, those are syntactically
wrong.)

Second, you don't need to start a nested brace to do a
simple forwared.

Third, you should get in the habit of quoting dots, as they
are special characters to procmail when unquoted (meaning
"any char").

        :0
        * ^From:(_dot_)*(_at_)mydomain\(_dot_)com
        * ^To:(_dot_)*linux(_at_)mydomoain\(_dot_)com
        ! linux-addr(_at_)mydomain(_dot_)com

You should put in some mail-loop checks, too.  Not to do so could
be catastrophic!  See man procmailex and man procmailrc.

All of this doesn't particularly explain why your attempt didn't
work, though.  Flawed as it is, it still looks like it would
have worked.  Do you have a log file?  Have you turned on
logging?  Verbose logging?


and i'd like to increase with two conditions... like
*    ^cc:(_dot_)*linux(_at_)mydomain(_dot_)com*
*    ^bcc:(_dot_)*linux(_at_)mydomain(_dot_)com*


The first makes me think you'd rather use

        * ^TO_linux(_at_)mydomain\(_dot_)com

The caret followed by all-caps "TO" followed by an
underscore is one atomic special procmail token.  See,
again, man procmailrc.

You won't have luck with bcc. unless you've configured your MTA
to show you the envelope information, usually dropped before
we ever get to procmail.

-- 
dman
_______________________________________________
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>