doc: use manpage role references to external man pages

Using manpage role references generates helpful links in html
documentation, while retaining the same boldface style in the man
pages.

The external man page site is configurable. The Debian manpage site
seems like a good fit for Notmuch.
This commit is contained in:
Jani Nikula 2021-05-21 23:44:09 +03:00 committed by David Bremner
parent 702635d5f6
commit 3baa61e0e5
10 changed files with 35 additions and 26 deletions

View file

@ -80,6 +80,11 @@ htmlhelp_basename = 'notmuchdoc'
# Despite the name, this actually affects manual pages as well. # Despite the name, this actually affects manual pages as well.
html_use_smartypants = False html_use_smartypants = False
# See:
# - https://www.sphinx-doc.org/en/master/usage/configuration.html#confval-manpages_url
# - https://manpages.debian.org/
manpages_url = 'https://manpages.debian.org/{page}.{section}.html'
# -- Options for manual page output --------------------------------------- # -- Options for manual page output ---------------------------------------
# One entry per manual page. List of tuples # One entry per manual page. List of tuples

View file

@ -21,8 +21,8 @@ Supported options for **address** include
``--format=``\ (**json**\ \|\ **sexp**\ \|\ **text**\ \|\ **text0**) ``--format=``\ (**json**\ \|\ **sexp**\ \|\ **text**\ \|\ **text0**)
Presents the results in either JSON, S-Expressions, newline Presents the results in either JSON, S-Expressions, newline
character separated plain-text (default), or null character character separated plain-text (default), or null character
separated plain-text (compatible with **xargs(1)** -0 option where separated plain-text (compatible with :manpage:`xargs(1)` -0
available). option where available).
``--format-version=N`` ``--format-version=N``
Use the specified structured output format version. This is Use the specified structured output format version. This is

View file

@ -27,7 +27,7 @@ the remaining arguments are search terms.
Supported options for **dump** include Supported options for **dump** include
``--gzip`` ``--gzip``
Compress the output in a format compatible with **gzip(1)**. Compress the output in a format compatible with :manpage:`gzip(1)`.
``--format=(sup|batch-tag)`` ``--format=(sup|batch-tag)``
Notmuch restore supports two plain text dump formats, both with Notmuch restore supports two plain text dump formats, both with
@ -36,8 +36,8 @@ Supported options for **dump** include
**batch-tag** **batch-tag**
The default **batch-tag** dump format is intended to more The default **batch-tag** dump format is intended to more
robust against malformed message-ids and tags containing robust against malformed message-ids and tags containing
whitespace or non-\ **ascii(7)** characters. Each line has the whitespace or non-\ :manpage:`ascii(7)` characters. Each line
form:: has the form::
+<*encoded-tag*\ > +<*encoded-tag*\ > ... -- id:<*quoted-message-id*\ > +<*encoded-tag*\ > +<*encoded-tag*\ > ... -- id:<*quoted-message-id*\ >
@ -54,11 +54,11 @@ Supported options for **dump** include
**sup** **sup**
The **sup** dump file format is specifically chosen to be The **sup** dump file format is specifically chosen to be
compatible with the format of files produced by sup-dump. So compatible with the format of files produced by
if you've previously been using sup for mail, then the :manpage:`sup-dump(1)`. So if you've previously been using sup
**notmuch restore** command provides you a way to import all for mail, then the **notmuch restore** command provides you a
of your tags (or labels as sup calls them). Each line has the way to import all of your tags (or labels as sup calls
following form:: them). Each line has the following form::
<*message-id*\ > **(** <*tag*\ > ... **)** <*message-id*\ > **(** <*tag*\ > ... **)**

View file

@ -41,8 +41,9 @@ Supported options for **emacs-mua** include
Even if a window system is available, use the current terminal. Even if a window system is available, use the current terminal.
``--client`` ``--client``
Use **emacsclient**, rather than **emacs**. For **emacsclient** to Use :manpage:`emacsclient(1)`, rather than
work, you need an already running Emacs with a server, or use :manpage:`emacs(1)`. For :manpage:`emacsclient(1)` to work, you
need an already running Emacs with a server, or use
``--auto-daemon``. ``--auto-daemon``.
``--auto-daemon`` ``--auto-daemon``
@ -60,9 +61,9 @@ Supported options for **emacs-mua** include
Output the resulting elisp to stdout instead of evaluating it. Output the resulting elisp to stdout instead of evaluating it.
The supported positional parameters and short options are a compatible The supported positional parameters and short options are a compatible
subset of the **mutt** MUA command-line options. The options and subset of the :manpage:`mutt(1)` MUA command-line options. The options
positional parameters modifying the message can't be combined with the and positional parameters modifying the message can't be combined with
mailto: URL. the mailto: URL.
Options may be specified multiple times. Options may be specified multiple times.
@ -78,4 +79,6 @@ ENVIRONMENT VARIABLES
SEE ALSO SEE ALSO
======== ========
**notmuch(1)**, **emacsclient(1)**, **mutt(1)** **notmuch(1)**,
:manpage:`emacsclient(1)`,
:manpage:`mutt(1)`

View file

@ -86,7 +86,7 @@ Supported options for **reply** include
Use ``false`` to avoid even automatic decryption. Use ``false`` to avoid even automatic decryption.
Non-automatic decryption expects a functioning Non-automatic decryption expects a functioning
**gpg-agent(1)** to provide any needed credentials. Without :manpage:`gpg-agent(1)` to provide any needed credentials. Without
one, the decryption will likely fail. one, the decryption will likely fail.
Default: ``auto`` Default: ``auto``

View file

@ -77,9 +77,9 @@ GZIPPED INPUT
============= =============
\ **notmuch restore** will detect if the input is compressed in \ **notmuch restore** will detect if the input is compressed in
**gzip(1)** format and automatically decompress it while reading. This :manpage:`gzip(1)` format and automatically decompress it while
detection does not depend on file naming and in particular works for reading. This detection does not depend on file naming and in
standard input. particular works for standard input.
SEE ALSO SEE ALSO
======== ========

View file

@ -27,8 +27,8 @@ Supported options for **search** include
``--format=``\ (**json**\ \|\ **sexp**\ \|\ **text**\ \|\ **text0**) ``--format=``\ (**json**\ \|\ **sexp**\ \|\ **text**\ \|\ **text0**)
Presents the results in either JSON, S-Expressions, newline Presents the results in either JSON, S-Expressions, newline
character separated plain-text (default), or null character character separated plain-text (default), or null character
separated plain-text (compatible with **xargs(1)** -0 option where separated plain-text (compatible with :manpage:`xargs(1)` -0
available). option where available).
``--format-version=N`` ``--format-version=N``
Use the specified structured output format version. This is Use the specified structured output format version. This is

View file

@ -130,7 +130,7 @@ Supported options for **show** include
Use ``false`` to avoid even automatic decryption. Use ``false`` to avoid even automatic decryption.
Non-automatic decryption (``stash`` or ``true``, in the absence of Non-automatic decryption (``stash`` or ``true``, in the absence of
a stashed session key) expects a functioning **gpg-agent(1)** to a stashed session key) expects a functioning :manpage:`gpg-agent(1)` to
provide any needed credentials. Without one, the decryption will provide any needed credentials. Without one, the decryption will
fail. fail.

View file

@ -90,7 +90,8 @@ will do its best to detect those and ignore them.
Mail storage that uses mbox format, (where one mbox file contains many Mail storage that uses mbox format, (where one mbox file contains many
messages), will not work with notmuch. If that's how your mail is messages), will not work with notmuch. If that's how your mail is
currently stored, it is recommended you first convert it to maildir currently stored, it is recommended you first convert it to maildir
format with a utility such as mb2md before running **notmuch setup .** format with a utility such as :manpage:`mb2md(1)` before running
**notmuch setup**.
Invoking ``notmuch`` with no command argument will run **setup** if the Invoking ``notmuch`` with no command argument will run **setup** if the
setup command has not previously been completed. setup command has not previously been completed.
@ -152,7 +153,7 @@ of notmuch.
**NOTMUCH\_TALLOC\_REPORT** **NOTMUCH\_TALLOC\_REPORT**
Location to write a talloc memory usage report. See Location to write a talloc memory usage report. See
**talloc\_enable\_leak\_report\_full** in **talloc(3)** for more **talloc\_enable\_leak\_report\_full** in :manpage:`talloc(3)` for more
information. information.
**NOTMUCH\_DEBUG\_QUERY** **NOTMUCH\_DEBUG\_QUERY**

View file

@ -39,7 +39,7 @@ indicate user-supplied values).
Some of the prefixes with <regex> forms can be also used to restrict Some of the prefixes with <regex> forms can be also used to restrict
the results to those whose value matches a regular expression (see the results to those whose value matches a regular expression (see
**regex(7)**) delimited with //, for example:: :manpage:`regex(7)`) delimited with //, for example::
notmuch search 'from:"/bob@.*[.]example[.]com/"' notmuch search 'from:"/bob@.*[.]example[.]com/"'