[neomutt-users] *-hook settings. I'm confused

Andrew Sullivan ajs at anvilwalrusden.com
Tue Aug 6 18:05:51 CEST 2019


On Mon, Aug 05, 2019 at 09:45:11PM -0700, Chris Bennett wrote:

> OK, let me explain much better. Right now, nothing anywhere is using
> IMAP. Just spool files.

Ok.  I'm going to set aside the IMAP issue because I think that's a
distraction.  The mechanism by which you _fetch_ the mail is unrelated
to the mechanism by which you determine what address you want to
respond from and so on.

> different email addresses sent with SMTP aliases file to a single user.

That is entirely possible.  

> So I would like to have an INBOX
> OpenBSD.misc
> OpenBSD.ports
> OpenBSD.tech
> OpenSMTPD.misc
> 
> and so forth. Preferably with different email addresses, but not
> mandatory.

If it were me, I'd do that with server-side filing ("mail rules" or
whatever -- I use sieve, but there's more than one way to do this).
Just send them all to a single mailbox.

But regardless, it seems that you want (e.g.) your mail for purpose 1
to come to "purpose1 at example.com" and your mail for purpose 2 to come
to "purpose2 at example.com".  Then, when you reply, you want your mail
to come from whatever address you received it on.  This is totally
possible in mutt.  What you need is the alternates command.  For
instance, my .muttrc says

	alternates ".*@crankycanuck.ca$|.*@yitter.info$|.*@anvilwalrusden.com$|.*@anvilwalrusden.ca$|.*@latrantes.info$|sullivan at isoc.org"

Notice the .* in several of those.  That means that anything at that
domain is me.

> Can I get this to work off of a spoolfile with Maildir?
> Do I need to add-in the IMAP to make this work?
> Working IMAP and Maildir is the goal, so if let's skip the just off the
> spoolfile part is best, not a problem.

The spoolfile/IMAP distinction is irrelevant for this, if you use the
technique above.

Hope that helps!

A

-- 
Andrew Sullivan
ajs at anvilwalrusden.com


More information about the neomutt-users mailing list