Skip to content

Commit 77c643c

Browse files
committed
Link to pyproject.toml guide in "Packaging Python projects" tutorial
Replace links to the "Declaring project metadata" specification with links to the "Writing pyproject.toml guide" since this is more likely what the user wants after a tutorial. Also harmonize with the guide slightly and leave link to version specifier specification (advanced reading) for the guide.
1 parent a918470 commit 77c643c

File tree

2 files changed

+13
-13
lines changed

2 files changed

+13
-13
lines changed

source/guides/writing-pyproject-toml.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ Most of the time, you will directly write the value of a field in
2828

2929
However, in some cases, it is useful to let your build backend compute
3030
the metadata for you. For example: many build backends can read the
31-
version from a ``__version__`` attribute in your code, or similar.
32-
In such cases, you should mark the field as dynamic using, e.g.,
31+
version from a ``__version__`` attribute in your code, a Git tag, or
32+
similar. In such cases, you should mark the field as dynamic using, e.g.,
3333

3434
.. code-block:: toml
3535

source/tutorials/packaging-projects.rst

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -214,17 +214,16 @@ following this tutorial.
214214
]
215215
216216
[project.urls]
217-
"Homepage" = "https://github.com/pypa/sampleproject"
218-
"Bug Tracker" = "https://github.com/pypa/sampleproject/issues"
217+
Homepage = "https://github.com/pypa/sampleproject"
218+
Issues = "https://github.com/pypa/sampleproject/issues"
219219
220220
- ``name`` is the *distribution name* of your package. This can be any name as
221221
long as it only contains letters, numbers, ``.``, ``_`` , and ``-``. It also
222222
must not already be taken on PyPI. **Be sure to update this with your
223223
username** for this tutorial, as this ensures you won't try to upload a
224224
package with the same name as one which already exists.
225-
- ``version`` is the package version. See the :ref:`version specifier specification <version-specifiers>`
226-
for more details on versions. Some build backends allow it to be specified
227-
another way, such as from a file or a git tag.
225+
- ``version`` is the package version. (Some build backends allow it to be
226+
specified another way, such as from a file or Git tag.)
228227
- ``authors`` is used to identify the author of the package; you specify a name
229228
and an email for each author. You can also list ``maintainers`` in the same
230229
format.
@@ -233,9 +232,9 @@ following this tutorial.
233232
package. This is shown on the package detail page on PyPI.
234233
In this case, the description is loaded from :file:`README.md` (which is a
235234
common pattern). There also is a more advanced table form described in the
236-
:ref:`project metadata specification <declaring-project-metadata>`.
235+
:ref:`pyproject.toml guide <writing-pyproject-toml>`.
237236
- ``requires-python`` gives the versions of Python supported by your
238-
project. Installers like :ref:`pip` will look back through older versions of
237+
project. An installer like :ref:`pip` will look back through older versions of
239238
packages until it finds one that has a matching Python version.
240239
- ``classifiers`` gives the index and :ref:`pip` some additional metadata
241240
about your package. In this case, the package is only compatible with Python
@@ -247,10 +246,11 @@ following this tutorial.
247246
- ``urls`` lets you list any number of extra links to show on PyPI.
248247
Generally this could be to the source, documentation, issue trackers, etc.
249248

250-
See the :ref:`project metadata specification <declaring-project-metadata>` for
251-
details on these and other fields that can be defined in the ``[project]``
252-
table. Other common fields are ``keywords`` to improve discoverability and the
253-
``dependencies`` that are required to install your package.
249+
See the :ref:`pyproject.toml guide <writing-pyproject-toml>` for details
250+
on these and other fields that can be defined in the ``[project]``
251+
table. Other common fields are ``keywords`` to improve discoverability
252+
and the ``dependencies`` that are required to install your package.
253+
254254

255255
Creating README.md
256256
------------------

0 commit comments

Comments
 (0)