Skip to content

Deactive macos-intel and windows 32bit since jaxlib is not supported … #34

Deactive macos-intel and windows 32bit since jaxlib is not supported …

Deactive macos-intel and windows 32bit since jaxlib is not supported … #34

Workflow file for this run

# This workflow will upload a Python Package using Twine when a release is created
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
name: Build and upload Python Package
on:
workflow_dispatch:
pull_request:
push:
branches:
- main
release:
types:
- published
permissions:
contents: read
jobs:
build_wheels:
name: Build wheels for ${{ matrix.os }}
runs-on: ${{ matrix.runs-on }}
strategy:
matrix:
os: [ linux-intel, linux-arm, windows, macos-arm ]
include:
- archs: auto
platform: auto
- os: linux-intel
runs-on: ubuntu-latest
- os: linux-arm
runs-on: ubuntu-24.04-arm
- os: windows
runs-on: windows-latest
archs: AMD64
- os: macos-arm
# macos-14+ (including latest) are ARM64 runners
runs-on: macos-latest
archs: auto,universal2
steps:
- uses: actions/checkout@v4
- name: Build wheels
uses: pypa/[email protected]
env:
CIBW_PLATFORM: ${{ matrix.platform }}
CIBW_ARCHS: ${{ matrix.archs }}
MACOSX_DEPLOYMENT_TARGET: "10.13"
- uses: actions/upload-artifact@v4
with:
name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }}
path: ./wheelhouse/*.whl
build_sdist:
name: Build source distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build sdist
run: pipx run build --sdist
- uses: actions/upload-artifact@v4
with:
name: cibw-sdist
path: dist/*.tar.gz
publish-to-pypi:
name: Publish Python distribution to PyPI
if: startsWith(github.ref, 'refs/tags/') # only publish to PyPI on tag pushes
needs:
- build_wheels
- build_sdist
runs-on: ubuntu-latest
environment: release
permissions:
id-token: write # IMPORTANT: mandatory for trusted publishing
steps:
- name: Download the dist file
uses: actions/download-artifact@v4
with:
pattern: cibw-*
path: dist
merge-multiple: true
- name: Publish distribution to PyPI
uses: pypa/gh-action-pypi-publish@release/v1