[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [msmtp-users] Matching an account with a "plussed" address



On Tue, 25. Jul 2006, 11:07:04 +0200, Stephane Bortzmeyer wrote:
> I'm currently using msmtp from mutt and I choose the account based on
> the "from" (mutt is configured with envelope_from=yes).
> 
> It works with "ordinary" addresses like "stephane@...51...". But
> I'm an user of "plussed" addresses like
> "stephane+amazon@...51..." because it allows me to have many
> identities without the trouble of configuring them.
> 
> mutt is fine with them (in alternates, for instance, you can set
> addresses with stephane\+[^@]+ and therefore all plussed addresses are
> accepted) but not msmtp.
> 
> How to match a plussed address?

I'm not sure if I understand the problem correctly.

Do all the "plussed" addresses mean different variants of the same
mailbox, and should therefore all choose the same account in the msmtp
configuration file?

This is currently not possible, because msmtp does not know about
any special meaning of '+'. 
If you cannot use the --account option to choose an account, you could
list all "plussed" addresses explicitly:

account my-account
from stephane@...51...
host ...
user ...
...
account my-account+amazon: my-account
from stephane+amazon@...51...
account my-account+ebay: my-account
from stephane+ebay@...51...
...

But this is a hassle, and it adds the "plussed-part" to the
envelope-from address (is this intended?)


It would be possible to teach msmtp about "plussed" addresses, and make
it ignore the "plussed-part" when searching for a from address.  This
could be made configurable if it causes trouble for other users.

Martin