On Sat, Aug 22, 2009 at 08:54:34AM -0400, Patrick Shanahan wrote:
Date: Sat, 22 Aug 2009 08:54:34 -0400
From: Patrick Shanahan <ptilopt...@gmail.com>
To: mutt-users@mutt.org
Subject: Re: local mail
User-Agent: Mutt/1.5.20 (2009-06-14)
* Gerard Robin <g.rob...@free.fr> [08-22-09 02:32]:
--------------------------8<-----------------------------------------------
when user1 send a mail to user2 locally i.e. To: us...@nameofmybox, user2
receive the mail from g.rob...@free.fr.
Is it possible that I edit my .muttrc so that:
1 When I send a mail to the outside the "From" is g.rob...@free.fr.
2 When I send mail locally (to user2) the "From" is us...@nameofmybox.
Look in the fine manual for "send-hook"
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Change settings based upon message recipient
#
# send-hook [!]<pattern> <command>
#
# <command> is executed when sending mail to an address matching <pattern>
ie: send-hook @name_of_my_box <user1>@name_of_my_box
The problem arises when I send mails to users (locally)with the crontab.
A perhaps simpler solution would be to create a second version of your
~/.muttrc, maybe ~/.muttrc.cron, and call it when mailing from cron. Set
the desired "From" address in .muttrc.cron.
Thanks, with this method it works fine.
(with send-hook it does not work ... )
There is *much* very good explanatin in the fine manual :^).
I do not agree with you regarding send-hook ...
Patrick Shanahan Plainfield, Indiana, USA HOG # US1244711
http://wahoo.no-ip.org Photo Album: http://wahoo.no-ip.org/gallery2
Registered Linux User #207535 @ http://counter.li.org
Thanks again
--
GĂ©rard