unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* Emacs: prevent notmuch from tampering with message headers & settings
@ 2021-05-11 18:01 Tory S. Anderson
  2021-05-13 11:38 ` David Bremner
  0 siblings, 1 reply; 6+ messages in thread
From: Tory S. Anderson @ 2021-05-11 18:01 UTC (permalink / raw)
  To: notmuch

As an emacs user, I use notmuch for searching and indexing my mail, and love it. The only problem is that every time I open a message in notmuch, it overwrites my message configuration for sending mails. In particular, it seems to change my headers, and my completion-methods. I need to reset this every time right now. How can I prevent Notmuch from messing with any of these?

- Tory

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Emacs: prevent notmuch from tampering with message headers & settings
  2021-05-11 18:01 Emacs: prevent notmuch from tampering with message headers & settings Tory S. Anderson
@ 2021-05-13 11:38 ` David Bremner
  2021-05-13 15:58   ` Tory S. Anderson
  0 siblings, 1 reply; 6+ messages in thread
From: David Bremner @ 2021-05-13 11:38 UTC (permalink / raw)
  To: Tory S. Anderson, notmuch; +Cc: David Edmondson

webdev@toryanderson.com (Tory S. Anderson) writes:

> As an emacs user, I use notmuch for searching and indexing my mail,
> and love it. The only problem is that every time I open a message in
> notmuch, it overwrites my message configuration for sending mails. In
> particular, it seems to change my headers, and my
> completion-methods. I need to reset this every time right now. How can
> I prevent Notmuch from messing with any of these?

How are you sending mail?  Do you end up in notmuch-message-mode (in the
mode line it looks like Message[Notmuch])?

I see that notmuch.el overrides mail-user-agent, which I guess maybe it
shouldn't.  For what it's worth, the code to do that is more than 10
years old.

d

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Emacs: prevent notmuch from tampering with message headers & settings
  2021-05-13 11:38 ` David Bremner
@ 2021-05-13 15:58   ` Tory S. Anderson
  2021-05-13 23:24     ` David Bremner
  0 siblings, 1 reply; 6+ messages in thread
From: Tory S. Anderson @ 2021-05-13 15:58 UTC (permalink / raw)
  To: David Bremner; +Cc: notmuch, David Edmondson

I send mail with either global C-x m (compose-mail) or from my gnus buffer when I reply to a message. In both cases, if I happen to have visited a notmuch search result previously, it has changed my headers and completion methods. Yeah, over-writing mail-user-agent seems to be the case -- I see that is exactly what has happened. Any idea how can I stop it?

- Tory

David Bremner <david@tethera.net> writes:

> webdev@toryanderson.com (Tory S. Anderson) writes:
>
>> As an emacs user, I use notmuch for searching and indexing my mail,
>> and love it. The only problem is that every time I open a message in
>> notmuch, it overwrites my message configuration for sending mails. In
>> particular, it seems to change my headers, and my
>> completion-methods. I need to reset this every time right now. How can
>> I prevent Notmuch from messing with any of these?
>
> How are you sending mail?  Do you end up in notmuch-message-mode (in the
> mode line it looks like Message[Notmuch])?
>
> I see that notmuch.el overrides mail-user-agent, which I guess maybe it
> shouldn't.  For what it's worth, the code to do that is more than 10
> years old.
>
> d

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Emacs: prevent notmuch from tampering with message headers & settings
  2021-05-13 15:58   ` Tory S. Anderson
@ 2021-05-13 23:24     ` David Bremner
  2021-05-19 13:42       ` Tory S. Anderson
  0 siblings, 1 reply; 6+ messages in thread
From: David Bremner @ 2021-05-13 23:24 UTC (permalink / raw)
  To: Tory S. Anderson; +Cc: notmuch, David Edmondson

"Tory S. Anderson" <webdev@toryanderson.com> writes:

> I send mail with either global C-x m (compose-mail) or from my gnus
> buffer when I reply to a message. In both cases, if I happen to have
> visited a notmuch search result previously, it has changed my headers
> and completion methods. Yeah, over-writing mail-user-agent seems to be
> the case -- I see that is exactly what has happened. Any idea how can
> I stop it?
>
> - Tory

You can try adding something like

(eval-after-load 'notmuch
                 (lambda () (setq mail-user-agent 'message-user-agent)))

to your emacs startup file (e.g. .emacs.d/init.el)
                 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Emacs: prevent notmuch from tampering with message headers & settings
  2021-05-13 23:24     ` David Bremner
@ 2021-05-19 13:42       ` Tory S. Anderson
  2021-05-19 14:45         ` Tomi Ollila
  0 siblings, 1 reply; 6+ messages in thread
From: Tory S. Anderson @ 2021-05-19 13:42 UTC (permalink / raw)
  To: David Bremner; +Cc: notmuch, David Edmondson

I've made a branch with a change that should avoid ruining existing behavior for anyone not trying to preserve their mail-user-agent. How can I submit this thing?

David Bremner <david@tethera.net> writes:

> "Tory S. Anderson" <webdev@toryanderson.com> writes:
>
>> I send mail with either global C-x m (compose-mail) or from my gnus
>> buffer when I reply to a message. In both cases, if I happen to have
>> visited a notmuch search result previously, it has changed my headers
>> and completion methods. Yeah, over-writing mail-user-agent seems to be
>> the case -- I see that is exactly what has happened. Any idea how can
>> I stop it?
>>
>> - Tory
>
> You can try adding something like
>
> (eval-after-load 'notmuch
>                  (lambda () (setq mail-user-agent 'message-user-agent)))
>
> to your emacs startup file (e.g. .emacs.d/init.el)
>                  

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Emacs: prevent notmuch from tampering with message headers & settings
  2021-05-19 13:42       ` Tory S. Anderson
@ 2021-05-19 14:45         ` Tomi Ollila
  0 siblings, 0 replies; 6+ messages in thread
From: Tomi Ollila @ 2021-05-19 14:45 UTC (permalink / raw)
  To: Tory S. Anderson, David Bremner; +Cc: notmuch, David Edmondson

On Wed, May 19 2021, Tory S. Anderson wrote:

> I've made a branch with a change that should avoid ruining existing
> behavior for anyone not trying to preserve their mail-user-agent. How can
> I submit this thing?

IIRC David already posted something on this mailing list.

but anyway; FYI, and reminder for others:

https://notmuchmail.org/contributing/

Tomi

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-05-19 14:45 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-11 18:01 Emacs: prevent notmuch from tampering with message headers & settings Tory S. Anderson
2021-05-13 11:38 ` David Bremner
2021-05-13 15:58   ` Tory S. Anderson
2021-05-13 23:24     ` David Bremner
2021-05-19 13:42       ` Tory S. Anderson
2021-05-19 14:45         ` Tomi Ollila

unofficial mirror of notmuch@notmuchmail.org

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://yhetil.org/notmuch/0 notmuch/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 notmuch notmuch/ https://yhetil.org/notmuch \
		notmuch@notmuchmail.org
	public-inbox-index notmuch

Example config snippet for mirrors.
Newsgroups are available over NNTP:
	nntp://news.yhetil.org/yhetil.mail.notmuch.general
	nntp://news.gmane.io/gmane.mail.notmuch.general


code repositories for project(s) associated with this inbox:

	notmuch.git.git (no URL configured)

AGPL code for this site: git clone http://ou63pmih66umazou.onion/public-inbox.git