Skip to content

Merge pull request #7 from meelgroup/minor-improvements #53

Merge pull request #7 from meelgroup/minor-improvements

Merge pull request #7 from meelgroup/minor-improvements #53

Workflow file for this run

name: python-wheel-build
on:
push:
branches:
- master
jobs:
build_wheels:
name: Build wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-2022]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v3
- name: Install cibuildwheel
run: python -m pip install cibuildwheel
- name: Build wheels
uses: pypa/cibuildwheel@d04cacbc9866d432033b1d09142936e6a0e2121a #v2.23.2
env:
CIBW_BUILD: "cp310-* cp311-* cp312-* cp313-*"
CIBW_ARCHS: auto64
CIBW_SKIP: "*-win32 *-manylinux_i686"
with:
output-dir: wheelhouse
- name: Get wheel filename
id: wheel-name
run: |
WHEEL_NAME=$(ls ./wheelhouse/pycmsgen-*.whl | xargs -n 1 basename)
echo "wheel_name=${WHEEL_NAME}" >> $GITHUB_OUTPUT
- uses: actions/upload-artifact@v4
with:
path: ./wheelhouse/pycmsgen-*.whl
name: cmsgen-${{ matrix.os }}_${{ steps.wheel-name.outputs.wheel-name }}
- name: Install twine
run: python -m pip install twine
- name: Publish wheels to PyPI
env:
TWINE_USERNAME: "__token__"
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
run: |
twine upload --skip-existing --disable-progress-bar ./wheelhouse/pycmsgen-*.whl