Skip to content

v0.8.9p9

v0.8.9p9 #27

Workflow file for this run

on:
release:
types: [created, edited]
name: publish pypi
jobs:
linux:
runs-on: ubuntu-latest
strategy:
matrix:
python: [
{ version: '3.8', abi: 'cp38-cp38' },
{ version: '3.9', abi: 'cp39-cp39' },
{ version: '3.10', abi: 'cp310-cp310' },
{ version: '3.11', abi: 'cp311-cp311' },
{ version: '3.12', abi: 'cp312-cp312' },
]
target: [x86_64, i686, aarch64, armv7]
steps:
- uses: actions/checkout@v4
- uses: messense/maturin-action@v1
name: build pylancelot for linux (${{ matrix.target }})
env:
PYO3_CROSS_LIB_DIR: /opt/python/${{ matrix.python.abi }}/lib
with:
maturin-version: 1.4.0
target: ${{ matrix.target }}
manylinux: auto
command: build
args: --interpreter=python${{ matrix.python.version }} --release --strip --manifest-path=./pylancelot/Cargo.toml
- uses: messense/maturin-action@v1
name: build pyflirt for linux (${{ matrix.target }})
env:
PYO3_CROSS_LIB_DIR: /opt/python/${{ matrix.python.abi }}/lib
with:
maturin-version: 1.4.0
target: ${{ matrix.target }}
manylinux: auto
command: build
args: --interpreter=python${{ matrix.python.version }} --release --strip --manifest-path=./pyflirt/Cargo.toml
- uses: actions/upload-artifact@v4
name: upload
with:
name: wheels-linux-${{ matrix.python.version }}-${{ matrix.target }}
path: target/wheels/*.whl
windows:
runs-on: windows-latest
strategy:
matrix:
target: [x64, x86]
python: [
{ version: '3.8' },
{ version: '3.9' },
{ version: '3.10' },
{ version: '3.11' },
{ version: '3.12' },
]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python.version }}
architecture: ${{ matrix.target }}
- name: install Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
default: true
- uses: messense/maturin-action@v1
name: build pylancelot for windows (${{ matrix.target }})
with:
maturin-version: 1.4.0
command: build
target: ${{ matrix.target }}
args: --interpreter=python${{ matrix.python.version }} --release --strip --manifest-path=./pylancelot/Cargo.toml
- uses: messense/maturin-action@v1
name: build pyflirt for windows (${{ matrix.target }})
with:
maturin-version: 1.4.0
command: build
target: ${{ matrix.target }}
args: --interpreter=python${{ matrix.python.version }} --release --strip --manifest-path=./pyflirt/Cargo.toml
- uses: actions/upload-artifact@v4
name: upload
with:
name: wheels-windows-${{ matrix.python.version }}-${{ matrix.target }}
path: target/wheels/*.whl
macos:
runs-on: macos-latest
strategy:
matrix:
python: [
{ version: '3.8' },
{ version: '3.9' },
{ version: '3.10' },
{ version: '3.11' },
{ version: '3.12' },
]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python.version }}
architecture: x64
- name: Setup cmake
uses: jwlawson/[email protected]
with:
cmake-version: '3.24.3'
- name: install Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
default: true
#
# aarch64 build
#
- name: Install aarch64-apple-darwin toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: aarch64-apple-darwin
- uses: messense/maturin-action@v1
name: build pylancelot for macos (universal2)
env:
# needed due to: https://stackoverflow.com/a/56092773/87207
MACOSX_DEPLOYMENT_TARGET: 10.9
with:
maturin-version: 1.4.0
command: build
args: --interpreter=python${{ matrix.python.version }} --release --target universal2-apple-darwin --strip --manifest-path=./pylancelot/Cargo.toml
- uses: messense/maturin-action@v1
name: build pyflirt for macos (universal2)
env:
MACOSX_DEPLOYMENT_TARGET: 10.9
with:
maturin-version: 1.4.0
command: build
args: --interpreter=python${{ matrix.python.version }} --release --target universal2-apple-darwin --strip --manifest-path=./pyflirt/Cargo.toml
#
# x86_64 build
#
- uses: messense/maturin-action@v1
name: build pylancelot for macos (x86_64)
env:
MACOSX_DEPLOYMENT_TARGET: 10.9
with:
maturin-version: 1.4.0
command: build
target: x86_64
args: --interpreter=python${{ matrix.python.version }} --release --strip --manifest-path=./pylancelot/Cargo.toml
- uses: messense/maturin-action@v1
name: build pyflirt for macos (x86_64)
env:
MACOSX_DEPLOYMENT_TARGET: 10.9
with:
maturin-version: 1.4.0
command: build
target: x86_64
args: --interpreter=python${{ matrix.python.version }} --release --strip --manifest-path=./pyflirt/Cargo.toml
- uses: actions/upload-artifact@v4
name: upload
with:
name: wheels-macos-${{ matrix.python.version }}
path: target/wheels/*.whl
pypi-publish:
runs-on: ubuntu-latest
if: "startsWith(github.ref, 'refs/tags/')"
needs: [ macos, windows, linux ]
environment:
name: release
permissions:
id-token: write
steps:
- uses: actions/download-artifact@v4
with:
path: artifacts/
- name: move files to dist/
run: |
shopt -s globstar # Enable recursive globbing (**)
mkdir dist/
cp -r artifacts/**/* dist/
- name: publish package
uses: pypa/gh-action-pypi-publish@f5622bde02b04381239da3573277701ceca8f6a0 # release/v1
with:
skip-existing: true
verbose: true
print-hash: true