chore: release 0.24.0 #39
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Upload to PyPI | |
on: | |
push: | |
tags: ["v*"] | |
jobs: | |
build-sdist: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: "3.11" | |
- name: Build sources | |
run: |- | |
pip install build | |
python -mbuild -n -s | |
- name: Upload sources | |
uses: actions/upload-artifact@v4 | |
with: | |
name: dist-sources | |
path: dist/*.tar.gz | |
retention-days: 2 | |
build-wheels: | |
runs-on: ${{matrix.os}} | |
strategy: | |
matrix: | |
include: | |
- { os: windows-latest, cibw_arch: AMD64 } | |
- { os: windows-latest, cibw_arch: ARM64 } | |
- { os: ubuntu-latest, cibw_arch: x86_64 } | |
- { os: ubuntu-latest, cibw_arch: aarch64, qemu_arch: arm64 } | |
- { os: macos-latest, cibw_arch: arm64 } | |
- { os: macos-latest, cibw_arch: x86_64 } | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- name: Set up QEMU | |
if: matrix.qemu_arch != '' | |
uses: docker/setup-qemu-action@v3 | |
with: | |
platforms: ${{matrix.qemu_arch}} | |
- name: Build wheels | |
uses: pypa/cibuildwheel@v2.22 | |
env: | |
CIBW_ARCHS: ${{matrix.cibw_arch}} | |
CIBW_SKIP: "pp* *-musllinux_aarch64" | |
# FIXME: only skip win_arm64 when the tests stop crashing | |
CIBW_TEST_SKIP: "*-*linux_aarch64 *-macosx_x86_64 *-win_*" | |
- name: Upload wheels | |
uses: actions/upload-artifact@v4 | |
with: | |
name: dist-wheels-${{matrix.os}}-${{matrix.cibw_arch}} | |
path: wheelhouse/*.whl | |
retention-days: 2 | |
release: | |
runs-on: ubuntu-latest | |
needs: [build-sdist, build-wheels] | |
steps: | |
- name: Download artifacts | |
uses: actions/download-artifact@v4 | |
with: | |
path: dist | |
pattern: dist-* | |
merge-multiple: true | |
- name: Check artifacts | |
run: ls -l dist | |
- name: Upload to pypi | |
uses: pypa/gh-action-pypi-publish@release/v1 | |
with: | |
password: ${{secrets.PYPI_API_TOKEN}} | |
- name: Create GitHub release | |
run: gh release create "$GITHUB_REF_NAME" --generate-notes | |
env: | |
GH_TOKEN: ${{github.token}} | |
GH_REPO: ${{github.repository}} |