procmail recipe to detect fetchmailed addrs?
i meant, procmail. it only FEELs like prickmail.
anybody got some pointers here?
On Mon, Oct 02, 2000 at 03:28:10PM -0500, will trillich wrote:
> (fetchmailed? i decree it to be a verb today.)
>
> i've got some old addresses
> will@pinncomp.net
> trillich@speedex.net
> trillich@usa.net
> and i use fetchmail to yank email from those into my active
> will@serensoft.com
> account.
>
> i'd like to phase out the older accounts...
>
> what kind of procmail recipe do i need to figure out
> the actual destination address of an email, so i can
> gently inform senders that i've got a new address?
>
> this doesn't quite get it--
>
>
> :0 hc
> * ^TO_.*@\/(pinncomp|speedex)
> {
> OLD=$MATCH
>
> # track who got reminded
> :0 hwc:old_addrs.lock
> | egrep '^Date:|^From:' >> to_$OLD
>
> # remind about new address
> :0 c
> * ! ^X-Loop: will@serensoft.com
> * ^TO_ \/[a-zA-Z0-9]+@(pinncomp|speedex)
> | (formail -r -I"Precedence: junk" -A"X-Loop: will@serensoft.com" ; \
> echo "You sent email to an old email address '$MATCH';" ; \
> echo "It's been forwarded to the new address 'will@serensoft.com'." ; \
> echo "Please use 'will@serensoft.com' in the future. Thanks." ) | $SENDMAIL -t
> }
>
> one isp adds a X-RCPT-TO header, but the other doesn't...
>
> suggestions solicited.
Reply to: