Skip to content

switch from test pypi repo #8

switch from test pypi repo

switch from test pypi repo #8

Workflow file for this run

name: Build wheels
on:
push:
tags:
- "v*.*.*"
jobs:
build_wheels:
name: Build wheels for ${{ matrix.platforms[1] }} with Python ${{ matrix.python }}
runs-on: ${{ matrix.platforms[0] }}
strategy:
matrix:
platforms:
- [ubuntu-20.04, manylinux_x86_64]
- [ubuntu-20.04, musllinux_x86_64]
- [macos-13, macosx_x86_64]
- [macos-14, macosx_arm64]
- [windows-2019, win_amd64]
- [windows-2019, win32]
python: ["cp39", "cp310", "cp311", "cp312"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.9"
- name: Build wheels
uses: pypa/cibuildwheel@v2.18.1
env:
CIBW_BUILD: ${{ matrix.python }}-${{ matrix.platforms[1] }}
- uses: actions/upload-artifact@v4
with:
name: cibw-wheels-${{ matrix.python }}-${{ matrix.platforms[1] }}
path: ./wheelhouse/*.whl
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install twine
- name: Upload wheels to PyPI
if: success()
run: |
python -m twine upload wheelhouse/*.whl
env:
TWINE_USERNAME: "__token__"
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
build_sdist:
name: Build source distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.9"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install build twine
- name: Build source distribution
run: python3 -m build --sdist
- uses: actions/upload-artifact@v4
with:
name: sdist
path: ./dist/*.tar.gz
- name: Upload source distribution to PyPI
if: success()
run: |
python -m twine upload dist/*.tar.gz
env:
TWINE_USERNAME: "__token__"
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}