Setting this according to --config was requested by Uwe
Kleine-König. There are some other ways that the configuration file
might be found in current notmuch, so check those as well.
As a bonus, fix a bug in the hook tests that left NOTMUCH_CONFIG set
even though a config file was provided via
Michael J Gruber writes:
>
> So, either notmuch should export `NOTMUCH_CONFIG` into the environment
> which it runs the hooks in (if overriden by `--config`), or, as Uwe
> suggests, and in the light of other variables like `NOTMUCH_PROFILE`,
> `--config` could be deprecated so that users
David Bremner venit, vidit, dixit 2021-04-27 14:34:30:
> Uwe Kleine-König 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
Uwe Kleine-König 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
>
>
Uwe Kleine-König 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
>
>
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