mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
#4244 use more generic Python *3* examples
This commit is contained in:
parent
7aaba1758a
commit
20dcbd367d
@ -87,7 +87,7 @@ linking:
|
|||||||
To add links to modules and objects in the Python standard library
|
To add links to modules and objects in the Python standard library
|
||||||
documentation, use::
|
documentation, use::
|
||||||
|
|
||||||
intersphinx_mapping = {'python': ('https://docs.python.org/3.6', None)}
|
intersphinx_mapping = {'python': ('https://docs.python.org/3', None)}
|
||||||
|
|
||||||
This will download the corresponding :file:`objects.inv` file from the
|
This will download the corresponding :file:`objects.inv` file from the
|
||||||
Internet and generate links to the pages under the given URI. The downloaded
|
Internet and generate links to the pages under the given URI. The downloaded
|
||||||
@ -97,12 +97,12 @@ linking:
|
|||||||
A second example, showing the meaning of a non-``None`` value of the second
|
A second example, showing the meaning of a non-``None`` value of the second
|
||||||
tuple item::
|
tuple item::
|
||||||
|
|
||||||
intersphinx_mapping = {'python': ('https://docs.python.org/3.6',
|
intersphinx_mapping = {'python': ('https://docs.python.org/3',
|
||||||
'python-inv.txt')}
|
'python-inv.txt')}
|
||||||
|
|
||||||
This will read the inventory from :file:`python-inv.txt` in the source
|
This will read the inventory from :file:`python-inv.txt` in the source
|
||||||
directory, but still generate links to the pages under
|
directory, but still generate links to the pages under
|
||||||
``https://docs.python.org/3.6``. It is up to you to update the inventory file
|
``https://docs.python.org/3``. It is up to you to update the inventory file
|
||||||
as new objects are added to the Python documentation.
|
as new objects are added to the Python documentation.
|
||||||
|
|
||||||
**Multiple target for the inventory**
|
**Multiple target for the inventory**
|
||||||
@ -116,7 +116,7 @@ linking:
|
|||||||
this to specify mirror sites for server downtime of the primary
|
this to specify mirror sites for server downtime of the primary
|
||||||
inventory::
|
inventory::
|
||||||
|
|
||||||
intersphinx_mapping = {'python': ('https://docs.python.org/3.6',
|
intersphinx_mapping = {'python': ('https://docs.python.org/3',
|
||||||
(None, 'python-inv.txt'))}
|
(None, 'python-inv.txt'))}
|
||||||
|
|
||||||
.. confval:: intersphinx_cache_limit
|
.. confval:: intersphinx_cache_limit
|
||||||
@ -141,7 +141,7 @@ Showing all links of an Intersphinx mapping file
|
|||||||
|
|
||||||
To show all Intersphinx links and their targets of an Intersphinx mapping file, run
|
To show all Intersphinx links and their targets of an Intersphinx mapping file, run
|
||||||
``python -msphinx.ext.intersphinx url-or-path``. This is helpful when searching for the root cause of a broken
|
``python -msphinx.ext.intersphinx url-or-path``. This is helpful when searching for the root cause of a broken
|
||||||
Intersphinx link in a documentation project. The following example prints the Intersphinx mapping of the Python 3.6
|
Intersphinx link in a documentation project. The following example prints the Intersphinx mapping of the Python 3
|
||||||
documentation::
|
documentation::
|
||||||
|
|
||||||
$ python -msphinx.ext.intersphinx https://docs.python.org/3.6/objects.inv
|
$ python -msphinx.ext.intersphinx https://docs.python.org/3/objects.inv
|
||||||
|
Loading…
Reference in New Issue
Block a user