nmh-workers
[Top] [All Lists]

Re: [Nmh-workers] Replying ... but not to "me" too

2014-03-26 08:27:28
Sigh.  My only point was ... if bob(_at_)local(_dot_)host(_dot_)name is not, 
in fact, a
valid email address for you, you'd be better served by changing
Local-Mailbox.  It does more things (things you'd likely want) than
Alternate-Mailboxes does.

I've tried this while also removing the Alternate-Mailboxes
entry.  It doesn't solve my original problem of suppressing
my (non-local @gmail.com) email address in replies.

Are you suggesting that I add both Local-Mailboxes and
Alternate-Mailboxes entries?

Did you use Local-MailboxES, or Local-Mailbox?  The latter is the
correct one (it's singular).  You could check exactly what nmh thinks is
your local mailbox by executing the command:

% ap -format '%(localmbox)' null

(ap lives in your nmh lib directory).  That should show you what nmh thinks
is your local mailbox, and that's what the Local-Mailbox setting changs.

When I first started using MH (in grad school), the default for
Local-Mailbox (<user>@<host>) was my actual mailbox address.  It
wasn't until much later, when I started using a laptop and
connecting via commercial ISPs, that my current situation arose,
where <user>@<host> has no use for email purposes.  (In fact, I
set up my repl*comps at that time to explicitly specify what my
addresses, for From:, Reply-To:, etc., are.  They do that to
this day.)

Let me expand on this a bit.

Local-Mailbox is a new feature, created as part of the address handling
cleanup done for 1.5.  Like you said, the "old" way MH used to operate
was that it would synthesize your local email address based on your local
username and hostname; there was no way to override that (nor was there
even a way to see what it thought it was).  The world has moved on since
then, so for 1.5 I created the code that let you override the local mailbox
setting.

So what exactly does Local-Mailbox _do_?  Well, in addition to matching
an email address as local (which really means it will match the
%(mymbox) format function), it will be output by the %(localmbox)
format function.  This is now used by component templates (components,
repl*comps, forwcomps, distcomps) to fill in the "From" field.  Now you
(and plenty of others) have been papering over this problem for a while
now by adjusting the relevant components files yourself, but after a bunch
of thrashing on the mailing list we all decided that we needed a better
solution.

So, Local-Mailbox changes nmh's idea of what your local mailbox is (which,
in practice, boils down to changing the output of %(localmbox)).  Compare
that to Alternate-Mailboxes (plural); what that does is simply add to the
list that %(mymbox) will match.  That, plus a little extra magic, is how
"local" email addresses don't end up in replies.

Okay, long digression.  What's the "right" solution?  IMHO, it's:

- If localuser(_at_)local(_dot_)host does not match your email address, add a
  Local-Mailbox line to your .mh_profile that has your complete email
  address (including your real name).
- If you have additional email addresses that you want nmh to consider a
  local address, add them to Alternate-Mailboxes.

--Ken

_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
https://lists.nongnu.org/mailman/listinfo/nmh-workers

<Prev in Thread] Current Thread [Next in Thread>