Skip to content

Commit 4ae9c91

Browse files
committed
include README.md contents in Python wheel long_description; add dist_check step to the GA workflow
1 parent ab7a1b2 commit 4ae9c91

File tree

2 files changed

+15
-2
lines changed

2 files changed

+15
-2
lines changed

.github/workflows/tests+artifacts.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,3 +72,15 @@ jobs:
7272
# uses: mxschmitt/action-tmate@v3
7373
# with:
7474
# limit-access-to-actor: true
75+
76+
dist_check:
77+
runs-on: ubuntu-latest
78+
needs: [build]
79+
steps:
80+
- uses: actions/setup-python@v2
81+
- run: pip install twine
82+
- uses: actions/download-artifact@v2
83+
with:
84+
name: dist
85+
path: dist
86+
- run: twine check --strict dist/*

setup.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
import re
99
import subprocess
1010
import sys
11-
11+
from pathlib import Path
1212
from setuptools import Extension, setup
1313
from setuptools.command.build_ext import build_ext
1414

@@ -128,7 +128,8 @@ def build_extension(self, ext): # pylint: disable=too-many-branches
128128
author="Sylwester Arabas",
129129
author_email="[email protected]",
130130
description="Python interface to PartMC",
131-
long_description="",
131+
long_description=(Path(__file__).parent / "README.md").read_text(),
132+
long_description_content_type="text/markdown",
132133
ext_modules=[CMakeExtension("PyPartMC")],
133134
cmdclass={"build_ext": CMakeBuild},
134135
zip_safe=False,

0 commit comments

Comments
 (0)