Skip to content

correctly exclude windows aarch64 #16

correctly exclude windows aarch64

correctly exclude windows aarch64 #16

Workflow file for this run

name: Build
on: [push, pull_request]
jobs:
build_wheels:
name: Build wheels on ${{ matrix.os }} ${{ matrix.arch }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-12, macos-14, windows-2019]
arch: [x86_64, aarch64]
exclude:
- os: macos-12
arch: aarch64
- os: macos-14
arch: x86_64
- os: windows-latest
arch: aarch64
steps:
- uses: actions/checkout@v4
- name: Set up QEMU
if: runner.os == 'Linux'
uses: docker/[email protected]
with:
platforms: arm64
- name: Setup Rust
if: runner.os != 'Linux'
uses: hecrj/setup-rust-action@v2
with:
profile: minimal
- name: Limit build jobs with QEMU builds
if: runner.os == 'Linux' && matrix.arch == 'aarch64'
run: echo "CARGO_BUILD_JOBS=1" >> $GITHUB_ENV
- name: Build wheels
uses: pypa/[email protected]
env:
CIBW_ARCHS_LINUX: ${{ matrix.arch }}
CIBW_ENVIRONMENT_PASS_LINUX: CARGO_BUILD_JOBS
- uses: actions/upload-artifact@v4
with:
name: wheels-${{ matrix.os }}-${{ matrix.arch }}
path: ./wheelhouse/*.whl
if-no-files-found: error
make_sdist:
name: Make SDist
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build SDist
run: pipx run build --sdist
- uses: actions/upload-artifact@v4
with:
name: sdist
path: dist/*.tar.gz
if-no-files-found: error
upload_all:
needs: [build_wheels, make_sdist]
runs-on: ubuntu-latest
environment:
name: release
url: https://pypi.org/p/simplefst
permissions:
contents: write
id-token: write
if: github.ref_type == 'tag'
steps:
- uses: actions/download-artifact@v4
with:
path: dist
merge-multiple: true
- name: Publish to PyPI
uses: pypa/[email protected]
- name: Create Github Release
uses: actions/create-release@v1
id: create_release
with:
draft: false
prerelease: false
release_name: ${{ github.ref_name }}
tag_name: ${{ github.ref }}
env:
GITHUB_TOKEN: ${{ github.token }}