On Thu, Aug 11, 2022 at 06:23:56PM +0200, Sébastien Hinderer wrote:
> Dear all,
> 
> Sorry if the question is off-topic, hopefully not completely though.
> 
> I am wondering what's the best way to use different SMTP servers to send
> mails, depending on which e-mail account I am currently using (the From 
> address).

There is arguably no best way; the best way *for you* will be specific
to how you use mail.  There are a number of ways to do this, but I
think the two most workable ones are:

1. Use hooks (e.g. folder-hook, send-hook, etc.) to set the variables
   for your smtp configuration, based on the folder you're in, the
   recipient you're sending to, etc..  See the mutt manual for more
   details on how to use hooks.

2. Use a macro, bound to some key, that changes the variables when you
   press it.  Again, the manual will have the details, but you might
   want to have a look at this:

     https://gitlab.com/muttmua/mutt/-/wikis/MuttGuide/Macros

There are other ways, like starting mutt with a different config file,
etc., and probably more that I haven't thought of, but I think one of
the two above will be easiest to manage.

-- 
Derek D. Martin    http://www.pizzashack.org/   GPG Key ID: 0xDFBEAD02
-=-=-=-=-
This message is posted from an invalid address.  Replying to it will result in
undeliverable mail due to spam prevention.  Sorry for the inconvenience.

Attachment: signature.asc
Description: PGP signature

Reply via email to