Skip to content

Commit c20eed0

Browse files
committed
Issue #22711: improve links in new distribution docs
- key term hyperlinks for distutils, setuptools & wheel - distutils landing page links directly to setuptools docs - short summary of setuptools benefits provided with link
1 parent 5cf454a commit c20eed0

File tree

2 files changed

+29
-11
lines changed

2 files changed

+29
-11
lines changed

Doc/distributing/index.rst

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -41,26 +41,28 @@ Key terms
4141
file format standards. They maintain a variety of tools, documentation
4242
and issue trackers on both `GitHub <https://github.com/pypa>`__ and
4343
`BitBucket <https://bitbucket.org/pypa/>`__.
44-
* ``distutils`` is the original build and distribution system first added to
45-
the Python standard library in 1998. While direct use of ``distutils`` is
46-
being phased out, it still laid the foundation for the current packaging
44+
* :mod:`distutils` is the original build and distribution system first added
45+
to the Python standard library in 1998. While direct use of :mod:`distutils`
46+
is being phased out, it still laid the foundation for the current packaging
4747
and distribution infrastructure, and it not only remains part of the
4848
standard library, but its name lives on in other ways (such as the name
4949
of the mailing list used to coordinate Python packaging standards
5050
development).
51-
* ``setuptools`` is a (largely) drop-in replacement for ``distutils`` first
51+
* `setuptools`_ is a (largely) drop-in replacement for :mod:`distutils` first
5252
published in 2004. Its most notable addition over the unmodified
53-
``distutils`` tools was the ability to declare dependencies on other
53+
:mod:`distutils` tools was the ability to declare dependencies on other
5454
packages. It is currently recommended as a more regularly updated
55-
alternative to ``distutils`` that offers consistent support for more
55+
alternative to :mod:`distutils` that offers consistent support for more
5656
recent packaging standards across a wide range of Python versions.
57-
* ``wheel`` (in this context) is a project that adds the ``bdist_wheel``
58-
command to ``distutils``/``setuptools``. This produces a cross platform
57+
* `wheel`_ (in this context) is a project that adds the ``bdist_wheel``
58+
command to :mod:`distutils`/`setuptools`_. This produces a cross platform
5959
binary packaging format (called "wheels" or "wheel files" and defined in
6060
:pep:`427`) that allows Python libraries, even those including binary
6161
extensions, to be installed on a system without needing to be built
6262
locally.
6363

64+
.. _setuptools: https://setuptools.pypa.io/en/latest/setuptools.html
65+
.. _wheel: http://wheel.readthedocs.org
6466

6567
Open source licensing and collaboration
6668
=======================================

Doc/library/distutils.rst

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,25 @@ additional modules into a Python installation. The new modules may be either
1313
collections of Python packages which include modules coded in both Python and C.
1414

1515
Most Python users will *not* want to use this module directly, but instead
16-
use the cross-version tools maintained by the Python Packaging Authority.
17-
Refer to the `Python Packaging User Guide <http://packaging.python.org>`_
18-
for more information.
16+
use the cross-version tools maintained by the Python Packaging Authority. In
17+
particular,
18+
`setuptools <https://setuptools.pypa.io/en/latest/setuptools.html>`__ is an
19+
enhanced alternative to :mod:`distutils` that provides:
20+
21+
* support for declaring project dependencies
22+
* additional mechanisms for configuring which files to include in source
23+
releases (including plugins for integration with version control systems)
24+
* the ability to declare project "entry points", which can be used as the
25+
basis for application plugin systems
26+
* the ability to automatically generate Windows command line executables at
27+
installation time rather than needing to prebuild them
28+
* consistent behaviour across all supported Python versions
29+
30+
The recommended `pip <https://pip.pypa.io/>`__ installer runs all
31+
``setup.py`` scripts with ``setuptools``, even if the script itself only
32+
imports ``distutils``. Refer to the
33+
`Python Packaging User Guide <http://packaging.python.org>`_ for more
34+
information.
1935

2036
For the benefits of packaging tool authors and users seeking a deeper
2137
understanding of the details of the current packaging and distribution

0 commit comments

Comments
 (0)