Skip to content

Commit f8b2bf8

Browse files
authored
Merge branch 'main' into 866-package-name
2 parents 83098f7 + 61480be commit f8b2bf8

1 file changed

Lines changed: 20 additions & 21 deletions

File tree

source/tutorials/packaging-projects.rst

Lines changed: 20 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -59,13 +59,13 @@ project's root directory - you will add content to them in the following steps.
5959
Creating a test folder
6060
----------------------
6161

62-
:file:`tests/` is a placeholder for unit test files. Leave it empty for now.
62+
:file:`tests/` is a placeholder for test files. Leave it empty for now.
6363

6464

6565
Creating pyproject.toml
6666
-----------------------
6767

68-
:file:`pyproject.toml` is the file that tells build tools (like ``pip`` 10+ and
68+
:file:`pyproject.toml` is the file that tells build tools (like ``pip`` and
6969
``build``) what system you are using and what is required for building. The
7070
default if this file is missing is to assume a classic setuptools build system,
7171
but it is better to be explicit; if you have a :file:`pyproject.toml` file, you
@@ -156,20 +156,20 @@ an escape hatch when absolutely necessary.
156156
This example package uses a relatively minimal set of metadata:
157157

158158
- ``name`` is the *distribution name* of your package. This can be any name as
159-
long as only contains letters, numbers, ``_`` , and ``-``. It also must not
159+
long as it only contains letters, numbers, ``_`` , and ``-``. It also must not
160160
already be taken on pypi.org. **Be sure to update this with your username,**
161161
as this ensures you won't try to upload a package with the same name as one
162-
which already exists when you upload the package.
162+
which already exists.
163163
- ``version`` is the package version. See :pep:`440` for more details on
164164
versions. You can use ``file:`` or ``attr:`` directives to read from a file or
165-
package attribute (simple attributes do not require import).
165+
package attribute.
166166
- ``author`` and ``author_email`` are used to identify the author of the
167167
package.
168168
- ``description`` is a short, one-sentence summary of the package.
169169
- ``long_description`` is a detailed description of the package. This is
170170
shown on the package detail page on the Python Package Index. In
171-
this case, the long description is loaded from :file:`README.md` which is
172-
a common pattern, using the ``file:`` directive.
171+
this case, the long description is loaded from :file:`README.md` (which is
172+
a common pattern) using the ``file:`` directive.
173173
- ``long_description_content_type`` tells the index what type of markup is
174174
used for the long description. In this case, it's Markdown.
175175
- ``url`` is the URL for the homepage of the project. For many projects, this
@@ -272,18 +272,18 @@ an escape hatch when absolutely necessary.
272272
minimal set:
273273

274274
- ``name`` is the *distribution name* of your package. This can be any name as
275-
long as only contains letters, numbers, ``_`` , and ``-``. It also must not
275+
long as it only contains letters, numbers, ``_`` , and ``-``. It also must not
276276
already be taken on pypi.org. **Be sure to update this with your username,**
277277
as this ensures you won't try to upload a package with the same name as one
278-
which already exists when you upload the package.
279-
- ``version`` is the package version see :pep:`440` for more details on
278+
which already exists.
279+
- ``version`` is the package version. See :pep:`440` for more details on
280280
versions.
281281
- ``author`` and ``author_email`` are used to identify the author of the
282282
package.
283283
- ``description`` is a short, one-sentence summary of the package.
284284
- ``long_description`` is a detailed description of the package. This is
285285
shown on the package detail page on the Python Package Index. In
286-
this case, the long description is loaded from :file:`README.md` which is
286+
this case, the long description is loaded from :file:`README.md`, which is
287287
a common pattern.
288288
- ``long_description_content_type`` tells the index what type of markup is
289289
used for the long description. In this case, it's Markdown.
@@ -379,21 +379,20 @@ The files listed above will be included automatically in your
379379
:term:`source distribution <Source Distribution (or "sdist")>`. If you want to control what goes in this
380380
explicitly, see :ref:`Using MANIFEST.in`.
381381

382-
The final :term:`built distribution <Built Distribution>` will
383-
have the Python files in the
384-
discovered or listed Python packages. If you want to control what goes here,
385-
such as to add data files, see :std:doc:`Including Data Files
386-
<setuptools:userguide/datafiles>` from the :std:doc:`setuptools docs
387-
<setuptools:index>`.
382+
The final :term:`built distribution <Built Distribution>` will have the Python
383+
files in the discovered or listed Python packages. If you want to control what
384+
goes here, such as to add data files, see
385+
:std:doc:`Including Data Files <setuptools:userguide/datafiles>`
386+
from the :std:doc:`setuptools docs <setuptools:index>`.
388387

389388
.. _generating archives:
390389

391390
Generating distribution archives
392391
--------------------------------
393392

394393
The next step is to generate :term:`distribution packages <Distribution
395-
Package>` for the package. These are archives that are uploaded to the Package
396-
Index and can be installed by :ref:`pip`.
394+
Package>` for the package. These are archives that are uploaded to the Python
395+
Package Index and can be installed by :ref:`pip`.
397396

398397
Make sure you have the latest versions of PyPA's ``build`` installed:
399398

@@ -454,8 +453,8 @@ Uploading the distribution archives
454453

455454
Finally, it's time to upload your package to the Python Package Index!
456455

457-
The first thing you'll need to do is register an account on ``Test PyPI``. Test
458-
PyPI is a separate instance of the package index intended for testing and
456+
The first thing you'll need to do is register an account on Test PyPI, which
457+
is a separate instance of the package index intended for testing and
459458
experimentation. It's great for things like this tutorial where we don't
460459
necessarily want to upload to the real index. To register an account, go to
461460
https://test.pypi.org/account/register/ and complete the steps on that page.

0 commit comments

Comments
 (0)