Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added a section on checking RST markup #554

Merged
merged 2 commits into from
Sep 24, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions source/guides/making-a-pypi-friendly-readme.rst
Original file line number Diff line number Diff line change
Expand Up @@ -81,3 +81,27 @@ and identifies the markup as GitHub-flavored Markdown:
long_description=long_description,
long_description_content_type='text/markdown'
)


Validating reStructuredText markup
----------------------------------

If your README is written in reStructuredText, any invalid markup will prevent
it from rendering, causing PyPI to instead just show the README's raw source.
You can check your README for markup errors before uploading as follows:

1. Install the latest version of `twine <https://github.com/pypa/twine>`_;
version 1.12.0 or higher is required::

pip install --upgrade twine

2. Build the sdist and wheel for your project as described under
:ref:`Packaging Your Project`.

3. Run ``twine check`` on the sdist and wheel::

twine check dist/*

This command will report any problems rendering your README. If your markup
renders fine, the command will output ``Checking distribution FILENAME:
Passed``.