@@ -152,8 +152,8 @@ As mentioned above, the primary feature of :file:`setup.py` is that it contains
152152a global ``setup() `` function. The keyword arguments to this function are how
153153specific details of your project are defined.
154154
155- The most relevant arguments are explained below. The snippets given are taken
156- from the `setup.py
155+ The most relevant arguments are explained below. Most of the snippets given are
156+ taken from the `setup.py
157157<https://github.com/pypa/sampleproject/blob/master/setup.py> `_ contained in the
158158`PyPA sample project <https://github.com/pypa/sampleproject >`_.
159159
@@ -361,12 +361,23 @@ packages
361361
362362 packages=find_packages(exclude=['contrib', 'docs', 'tests*']),
363363
364+ Set ``packages `` to a list of all :term: `packages <Import Package> ` in your
365+ project, including their subpackages, sub-subpackages, etc. Although the
366+ packages can be listed manually, ``setuptools.find_packages() `` finds them
367+ automatically. Use the ``exclude `` keyword argument to omit packages that are
368+ not intended to be released and installed.
364369
365- It is required to list the :term: `packages <Import Package> ` to be included
366- in your project. Although they can be listed manually,
367- ``setuptools.find_packages `` finds them automatically. Use the ``exclude ``
368- keyword argument to omit packages that are not intended to be released and
369- installed.
370+
371+ py_modules
372+ ~~~~~~~~~~
373+
374+ ::
375+
376+ py_modules=["six"],
377+
378+ If your project contains any single-file Python modules that aren't part of a
379+ package, set ``py_modules `` to a list of the names of the modules (minus the
380+ ``.py `` extension) in order to make :ref: `setuptools ` aware of them.
370381
371382
372383install_requires
@@ -490,16 +501,6 @@ keyword for pointing to pre-made scripts to install, the recommended approach to
490501achieve cross-platform compatibility is to use :ref: `console_scripts ` entry
491502points (see below).
492503
493- py_modules
494- ~~~~~~~~~~
495-
496- ::
497-
498- py_modules=["six"],
499-
500- It is required to list the names of single file modules that are to be included
501- in your project.
502-
503504entry_points
504505~~~~~~~~~~~~
505506
0 commit comments