Anthony Campbell wrote:
On 27 Dec 2009, Eduardo M KALINOWSKI wrote:
Anthony Campbell wrote:
I receive emails from a-u...@msn.com. I would like to redirect these
(and only these) to a-differentu...@gmail.com.
Is this possible with exim4? From reading the docs I think it should be
possible to do so using redirect but I cannot find an example of a
suitable script. Can anyone provide such an example and indicate where
it should go?
This is possible with filters. See
http://www.exim.org/exim-html-current/doc/html/filter.html for the syntax.
Your ~/.forward file can be an exim filter. I don't know if this is
configured by default in Debian's exim, but it's just a simple setting
in the config file:
http://www.exim.org/exim-html-current/doc/html/spec_html/index.html#toc0207
It's also possible to use a system filter, but that would affect all users.
I'd already found those. There's a lot of information but I couldn't see
an example of the (probably very simple) kind of script I would need to
put in ~/.forward.
Anthony
Somthing like the following in the .forward file of the account which
receives that e-mail
# Exim Filter
if error_message then finish endif
if $h_to: contains "a-u...@msn.com" then
deliver a-differentu...@gmail.com
finish
endif
I actually do something like this but also deliver it to the original
account. In which case change the clause to
if $h_to: contains "a-u...@msn.com" then
unseen deliver a-differentu...@gmail.com
save "$home/Maildir/.MailtoAuser/"
finish
endif
Also if you want to apply other rules - don't include the finish.
--
Alan Chandler
http://www.chandlerfamily.org.uk
--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org