procmail
[Top] [All Lists]

Re: newbie needs aliasing help

1997-08-29 13:59:40
In <3407184F(_dot_)6026(_at_)lifegrid(_dot_)com>, Kenneth J Blansette 
<ken(_at_)lifegrid(_dot_)com> writes:
I have been using procmail for a few months to simply alias email
addresses from my domain and forward them to individual pop accounts:

:0
^TO.*username@
! username(_at_)domain(_dot_)net

How do I forward a message that has a "Mail-For:
<username(_at_)mydomain(_dot_)com>" in the header?

:0
* (^TO.*username@)|(<username(_at_)domain>)
! username(_at_)domain(_dot_)other


Note this will not catch the situation when more than one person should get the
mail as only the first one will be delivered. Of course, if you don't mind 
ignoring invalid addressees, you could do something like


:0 c
* rules-for-user-1
! user1

:0 c
* rules-for-user-2
! user2

:0
/dev/null


Klaus Johannes Rusch
--
KlausRusch(_at_)atmedia(_dot_)net
http://www.atmedia.net/KlausRusch/

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