unofficial mirror of notmuch@notmuchmail.org
 help / color / Atom feed
* setting NOTMUCH_CONFIG in hooks
@ 2020-06-03  6:24 Uwe Kleine-König
  2020-06-03 14:12 ` David Bremner
  0 siblings, 1 reply; 2+ messages in thread
From: Uwe Kleine-König @ 2020-06-03  6:24 UTC (permalink / raw)
  To: notmuch


[-- Attachment #1.1.1: Type: text/plain, Size: 415 bytes --]

Hello,

when I run

	notmuch --config=$HOME/.notmuch-config-work new

NOTMUCH_CONFIG isn't set when the hooks are running. This would however
be quite useful such that e.g. afew uses the right database. Of course I
could do

	NOTMUCH_CONFIG=$HOME/.notmuch-config-work notmuch new

instead, but then it would be consequent to drop the --config option
from notmuch completely :-)

Best regards
Uwe


[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]



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

* Re: setting NOTMUCH_CONFIG in hooks
  2020-06-03  6:24 setting NOTMUCH_CONFIG in hooks Uwe Kleine-König
@ 2020-06-03 14:12 ` David Bremner
  0 siblings, 0 replies; 2+ messages in thread
From: David Bremner @ 2020-06-03 14:12 UTC (permalink / raw)
  To: Uwe Kleine-König, notmuch

Uwe Kleine-König <uwe@kleine-koenig.org> writes:

> Hello,
>
> when I run
>
> 	notmuch --config=$HOME/.notmuch-config-work new
>
> NOTMUCH_CONFIG isn't set when the hooks are running. This would however
> be quite useful such that e.g. afew uses the right database. Of course I
> could do
>
> 	NOTMUCH_CONFIG=$HOME/.notmuch-config-work notmuch new
>
> instead, but then it would be consequent to drop the --config option
> from notmuch completely :-)

Not really opposed, but it does seem like a wishlist item to me.

Two comments

1) I have planned for some weeks now to tear open the config handling,
which might affect this.

2) It would make sense to define an explicit set of environment
variables preserved or reset in hook environment at the same time as
this proposed change.

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

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-03  6:24 setting NOTMUCH_CONFIG in hooks Uwe Kleine-König
2020-06-03 14:12 ` David Bremner

unofficial mirror of notmuch@notmuchmail.org

Archives are clonable:
	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


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git