Skip to content

Commit 1680240

Browse files
committed
Use intersphinx references
1 parent 954931a commit 1680240

15 files changed

Lines changed: 48 additions & 43 deletions

source/conf.py

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -398,10 +398,22 @@
398398

399399
# Example configuration for intersphinx: refer to the Python standard library.
400400
intersphinx_mapping = {
401+
'build': ('https://pypa-build.readthedocs.io/en/stable/', None),
402+
'boltons': ('https://boltons.readthedocs.io/en/latest/', None),
403+
'cffi': ('https://cffi.readthedocs.io/en/latest/', None),
404+
'conda': ('https://conda.io/en/latest/', None),
405+
'distlib': ('https://distlib.readthedocs.io/en/latest/', None),
406+
'devpi': ('https://devpi.net/docs/devpi/devpi/latest/+doc', None),
407+
'dh-virtualenv': ('https://dh-virtualenv.readthedocs.io/en/latest/', None),
408+
'flexx': ('https://flexx.readthedocs.io/en/latest/', None),
401409
'openstack': ('https://docs.openstack.org/glance/latest/', None),
410+
'packaging': ('https://packaging.pypa.io/en/latest/', None),
411+
'packaging.python.org': ('https://packaging.python.org/', None),
412+
'piwheels': ('https://piwheels.readthedocs.io/en/latest/', None),
402413
'python': ('https://docs.python.org/3', None),
403414
'python2': ('https://docs.python.org/2', None),
404415
'pip': ('https://pip.pypa.io/en/latest/', None),
416+
'pipenv': ('https://pipenv.pypa.io/en/latest/', None),
405417
'scipy': ('https://www.scipy.org', None),
406418
'setuptools': ('https://setuptools.readthedocs.io/en/latest/', None),
407419
'tox': ('https://tox.readthedocs.io/en/latest/', None),
@@ -410,11 +422,11 @@
410422
'nox': ('https://nox.thea.codes/en/latest/', None),
411423
'pynsist': ('https://pynsist.readthedocs.io/en/latest/', None),
412424
'scipy': ('https://www.scipy.org', None),
425+
'spack': ('https://spack.readthedocs.io/en/latest/', None),
413426
'sphinx': ('https://www.sphinx-doc.org/en/master', None),
414427
'pybind11': ('https://pybind11.readthedocs.io/en/stable/', None),
415-
'cffi': ('https://cffi.readthedocs.io/en/latest/', None),
416428
'python-guide': ('https://docs.python-guide.org', None),
417-
429+
'virtualenv': ('https://virtualenv.pypa.io/en/stable/', None),
418430
}
419431

420432

source/glossary.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ Glossary
128128

129129
PyPA is a working group that maintains many of the relevant
130130
projects in Python packaging. They maintain a site at
131-
https://www.pypa.io/en/latest/, host projects on `GitHub
131+
:doc:`pypa.io <pypa:index>`, host projects on `GitHub
132132
<https://github.com/pypa>`_ and `Bitbucket
133133
<https://bitbucket.org/pypa>`_, and discuss issues on the
134134
`distutils-sig mailing list

source/guides/creating-and-discovering-plugins.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ a list of packages to :func:`setup`'s ``packages`` argument instead of using
120120
Using package metadata
121121
======================
122122

123-
`Setuptools`_ provides :doc:`special support
123+
:doc:`Setuptools <setuptools:index>` provides :doc:`special support
124124
<setuptools:userguide/entry_point>` for plugins. By providing the
125125
``entry_points`` argument to :func:`setup` in :file:`setup.py` plugins can
126126
register themselves for discovery.
@@ -171,5 +171,4 @@ Now the module of your choice can be imported by executing
171171
<python:library/importlib.metadata>`, most packaging tools other than setuptools
172172
provide support for defining entry points.
173173

174-
.. _Setuptools: https://setuptools.readthedocs.io/en/latest/
175174
.. _backport: https://importlib-metadata.readthedocs.io/en/latest/

source/guides/distributing-packages-using-setuptools.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -476,8 +476,8 @@ and it is interpreted relative to the installation prefix
476476
Each file name in ``files`` is interpreted relative to the :file:`setup.py`
477477
script at the top of the project source distribution.
478478

479-
For more information see the distutils section on `Installing Additional Files
480-
<https://docs.python.org/3/distutils/setupscript.html#installing-additional-files>`_.
479+
For more information see the distutils section on :ref:`Installing Additional Files
480+
<python:distutils-additional-files>`.
481481

482482
.. note::
483483

@@ -490,8 +490,8 @@ For more information see the distutils section on `Installing Additional Files
490490
``scripts``
491491
~~~~~~~~~~~
492492

493-
Although ``setup()`` supports a `scripts
494-
<https://docs.python.org/3/distutils/setupscript.html#installing-scripts>`_
493+
Although ``setup()`` supports a :ref:`scripts
494+
<python:distutils-installing-scripts>`
495495
keyword for pointing to pre-made scripts to install, the recommended approach to
496496
achieve cross-platform compatibility is to use :ref:`console_scripts` entry
497497
points (see below).

source/guides/hosting-your-own-index.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Hosting your own simple repository
66

77

88
If you wish to host your own simple repository [1]_, you can either use a
9-
software package like `devpi`_ or you can use simply create the proper
9+
software package like :doc:`devpi <devpi:index>` or you can use simply create the proper
1010
directory structure and use any web server that can serve static files and
1111
generate an autoindex.
1212

@@ -59,5 +59,4 @@ instruct users to add the URL to their installer's configuration.
5959
:pep:`503`.
6060
6161
62-
.. _devpi: https://devpi.net/docs/devpi/devpi/latest/%2Bd/index.html
6362
.. _Twisted: https://twistedmatrix.com/trac/

source/guides/installing-scientific-packages.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,8 @@ install the :ref:`scientific Python stack
9898
SciPy distributions
9999
-------------------
100100

101-
The SciPy site lists `several distributions
102-
<https://www.scipy.org/install.html>`__ that provide the full SciPy stack to
101+
The SciPy site lists :doc:`several distributions
102+
<scipy:install>` that provide the full SciPy stack to
103103
end users in an easy to use and update format.
104104

105105
Some of these distributions may not be compatible with the standard ``pip``

source/guides/making-a-pypi-friendly-readme.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ If your README is written in reStructuredText, any invalid markup will prevent
9797
it from rendering, causing PyPI to instead just show the README's raw source.
9898

9999
Note that Sphinx extensions used in docstrings, such as
100-
`directives and roles <https://www.sphinx-doc.org/en/master/usage/restructuredtext/index.html>`_
100+
:doc:`directives and roles <sphinx:usage/restructuredtext/index>`
101101
(e.g., "``:py:func:`getattr```" or "``:ref:`my-reference-label```"), are not allowed here and will result in error
102102
messages like "``Error: Unknown interpreted text role "py:func".``".
103103

source/guides/packaging-binary-extensions.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,14 +165,14 @@ wrapper modules up to date.
165165
hand, however, and is very repetitive, so may not be a good choice for
166166
wrapping large APIs.
167167

168-
* `pybind11 <https://pybind11.readthedocs.io/en/stable/>`__ is a pure C++11 library
168+
* :doc:`pybind11 <pybind11:index>` is a pure C++11 library
169169
that provides a clean C++ interface to the CPython (and PyPy) C API. It
170170
does not require a pre-processing step; it is written entirely in
171171
templated C++. Helpers are included for Setuptools or CMake builds. It
172172
was based on `Boost.Python <https://www.boost.org/doc/libs/1_76_0/libs/python/doc/html/index.html>`__,
173173
but doesn't require the Boost libraries or BJam.
174174

175-
* `cffi <https://cffi.readthedocs.io/en/latest/>`__ is a project created by some of the PyPy
175+
* :doc:`cffi <cffi:index>` is a project created by some of the PyPy
176176
developers to make it straightforward for developers that already know
177177
both Python and C to expose their C modules to Python applications. It
178178
also makes it relatively straightforward to wrap a C module based on its

source/guides/packaging-namespace-packages.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ in the `pkgutil namespace example project`_.
169169
pkg_resources-style namespace packages
170170
--------------------------------------
171171

172-
`Setuptools`_ provides the `pkg_resources.declare_namespace`_ function and
172+
:doc:`Setuptools <setuptools:index>` provides the `pkg_resources.declare_namespace`_ function and
173173
the ``namespace_packages`` argument to :func:`~setuptools.setup`. Together
174174
these can be used to declare namespace packages. While this approach is no
175175
longer recommended, it is widely present in most existing namespace packages.
@@ -236,7 +236,6 @@ to :func:`~setuptools.setup` in :file:`setup.py`. For example:
236236
A complete working example of two pkg_resources-style namespace packages can be found
237237
in the `pkg_resources namespace example project`_.
238238

239-
.. _setuptools: https://setuptools.readthedocs.io/en/latest/
240239
.. _pkg_resources.declare_namespace:
241240
https://setuptools.readthedocs.io/en/latest/pkg_resources.html#namespace-package-support
242241
.. _pkg_resources namespace example project:

source/guides/supporting-windows-using-appveyor.rst

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,4 +241,3 @@ For reference, the SDK setup support script is listed here:
241241
.. _Travis: https://travis-ci.org/
242242
.. _Github: https://github.com
243243
.. _Bitbucket: https://bitbucket.org/
244-
.. _Tox: https://tox.readthedocs.io/en/latest/

0 commit comments

Comments
 (0)