Skip to content

Commit

Permalink
Change wheel dist
Browse files Browse the repository at this point in the history
- Add Python 3.7
- Remove PyPy
- Github release
  • Loading branch information
dofuuz committed Aug 2, 2023
1 parent af74dd0 commit 93abf41
Showing 1 changed file with 25 additions and 10 deletions.
35 changes: 25 additions & 10 deletions .github/workflows/build-dist.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,21 @@ jobs:
submodules: true

- name: Build wheels
uses: pypa/cibuildwheel@v2.11.2
uses: pypa/cibuildwheel@v2.14.1
env:
# Skip builds(save time / avoid build error)
CIBW_SKIP: "cp36-* cp37-* pp37-* pp39-* *-musllinux_* *_i686"
CIBW_SKIP: "cp36-* pp* *-musllinux_* *_i686"
CIBW_ARCHS_MACOS: x86_64 arm64

- uses: actions/upload-artifact@v3
with:
path: ./wheelhouse/*.whl

- uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/v')
with:
files: ./wheelhouse/*.whl

build_archs:
name: Build wheels manylinux_aarch64
runs-on: ubuntu-20.04
Expand All @@ -49,16 +54,21 @@ jobs:
platforms: all

- name: Build wheels
uses: pypa/cibuildwheel@v2.11.2
uses: pypa/cibuildwheel@v2.14.1
env:
CIBW_ARCHS_LINUX: aarch64
CIBW_BUILD: cp*-manylinux_aarch64
CIBW_SKIP: "cp36-* cp37-*"
CIBW_SKIP: "cp36-*"

- uses: actions/upload-artifact@v3
with:
path: ./wheelhouse/*.whl

- uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/v')
with:
files: ./wheelhouse/*.whl

build_sdist:
name: Build source distribution
runs-on: ubuntu-20.04
Expand All @@ -74,6 +84,11 @@ jobs:
with:
path: dist/*.tar.gz

- uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/v')
with:
files: dist/*.tar.gz

upload_pypi:
needs: [build_wheels, build_archs, build_sdist]
runs-on: ubuntu-latest
Expand All @@ -89,10 +104,10 @@ jobs:
name: artifact
path: dist

- uses: pypa/gh-action-pypi-publish@v1.5.0
- uses: pypa/gh-action-pypi-publish@v1.8.8
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
# To test
# password: ${{ secrets.TEST_PYPI_API_TOKEN }}
# repository_url: https://test.pypi.org/legacy/
# user: __token__
# password: ${{ secrets.PYPI_API_TOKEN }}
To test
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
repository_url: https://test.pypi.org/legacy/

0 comments on commit 93abf41

Please sign in to comment.