unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: David Bremner <david@tethera.net>
To: inasprecali <inasprecali@disroot.org>, notmuch@notmuchmail.org
Subject: Re: Reusing descriptive sender name when replying
Date: Fri, 04 Feb 2022 20:35:47 -0400	[thread overview]
Message-ID: <87pmo2no9o.fsf@tethera.net> (raw)
In-Reply-To: <87mtjbsoo6.fsf@piccione>

inasprecali <inasprecali@disroot.org> writes:

> Hello, I have a question which is specifically about the Emacs
> frontend, but which could be about notmuch in general.  For your
> information, I’m using notmuch 0.31.4 and GNU Emacs 27.1.
>
> When pressing "r" to reply to a message, invoking the function
> "notmuch-show-reply-sender", the "From:" address used in the reply
> is automatically deduced from the message I’m currently replying
> to (looking at the code, it looks like it uses the
> notmuch-reply(1) command).  While the address itself is correct,
> the "real", descriptive name (the one used before the actual mail
> address in angled brackets, apologies if this is not the right
> terminology) seems to be always taken from the user.name setting
> in the .notmuch-config file, if any.  If it is not set, a
> descriptive name is not used at all and the address alone is used.

I think the two options supported out of the box are setting user.name
and setting notmuch-identities in emacs. The latter should let you
choose via completing-read at composition time. Otherwise there are more
complex options available via addons like gnus-alias [1] or
message-templ [2].

> My question is: is it possible to automatically reuse the same
> "descriptive" name in the From: header?  I’d like the following to
> be automatically generated just by looking at the original message
> to be replied to, using the same examples as before.  The To:
> header already reuses the same name, as expected.
>
> From: Bar <bar@bar.org>
> To: Foo <foo@foo.org>

I'm curious about your use case. Do you have a large number of values of
"Foo", conveniently provided by the senders of your messages?

At the moment I'm feeling a bit negative about putting more tweaks into
notmuch-reply; it seems like everybody wants something different but
small, and those kind of customizations are better done in the emacs
layer. OTOH I've changed my mind before about this kind of thing.

[1] https://github.com/hexmode/gnus-alias
[2] https://git.tethera.net/message-templ.git/\r

  reply	other threads:[~2022-02-05  0:35 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-31 19:14 Reusing descriptive sender name when replying inasprecali
2022-02-05  0:35 ` David Bremner [this message]
2022-02-05 11:27   ` inasprecali
2022-02-05 13:02     ` Dan Čermák
2022-02-05 18:34     ` David Bremner
2022-02-11 16:55     ` Alexander Adolf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://notmuchmail.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87pmo2no9o.fsf@tethera.net \
    --to=david@tethera.net \
    --cc=inasprecali@disroot.org \
    --cc=notmuch@notmuchmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).