Thanks to visit codestin.com
Credit goes to github.com

Skip to content

STUB 8

STUB 8 #7

Workflow file for this run

name: Build Wheels
on:
push:
branches:
- master
pull_request:
branches:
- master
release:
types: [created]
jobs:
build_wheels:
name: Build wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
#os: [ubuntu-latest, windows-latest, macos-13, macos-14]
os: [ubuntu-latest]
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install system build dependencies
run: |
if [[ "$RUNNER_OS" == "Linux" ]]; then
sudo apt update
sudo apt install -y build-essential wget tar cmake
elif [[ "$RUNNER_OS" == "macOS" ]]; then
brew install wget cmake
fi
- name: Build wheels using cibuildwheel
uses: pypa/[email protected]
env:
CIBW_BUILD: "cp37-* cp38-* cp39-* cp310-* cp311-* cp312-*"
CIBW_SKIP: "pp*"
CIBW_BEFORE_BUILD_LINUX: |
rpm -q admesh-devel || yum install -y --nogpgcheck /project/travis/*.x86_64.rpm; {pip} install Cython
CIBW_TEST_REQUIRES: "pytest"
CIBW_TEST_COMMAND: "pytest -v {project}/test"
- name: Upload built wheels as artifact
uses: actions/upload-artifact@v4
with:
name: cibw-wheels-${{ matrix.os }}
path: ./wheelhouse/*.whl
publish_pypi:
name: Publish to PyPI
needs: build_wheels
runs-on: ubuntu-latest
if: github.event_name == 'release'
steps:
- name: Download built wheels
uses: actions/download-artifact@v4
with:
path: dist
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_API_TOKEN }}