The library has supported profile-based configuration resolution (via the
NOTMUCH_PROFILE environment variable) for some time. This series exposes that
functionality as a --profile=PROFILE cli flag, making it consistent with
--config (which overrides NOTMUCH_CONFIG).

The design follows the --config pattern: parsed once in main() before subcommand
dispatch, rather than added to notmuch_shared_options. This keeps it from
appearing in every subcommand's --help output and avoids redundant re-parsing.

Shell completion updates (completion/) not covered in this series (possible
follow-up).

inwit (3):
  cli: add --profile option
  doc: document --profile option
  test: add tests for --profile CLI option

 doc/man1/notmuch.rst     | 13 +++++++++---
 notmuch.c                | 21 ++++++++++++++-----
 test/T035-read-config.sh | 44 ++++++++++++++++++++++++++++++++++++++++
 test/T055-path-config.sh | 25 ++++++++++++++++++++++-
 4 files changed, 94 insertions(+), 9 deletions(-)

-- 
2.53.0

_______________________________________________
notmuch mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to