mirror of
https://github.com/visioncortex/vtracer.git
synced 2026-09-28 15:01:20 -07:00
Update CI for the 1.0 workspace layout
- rust.yml: modernize (checkout@v4), build/test the whole workspace, add a wasm32 core build check and a Node package build+test job. Checks out visioncortex next to the repo so the local path dependency resolves. - python.yml: build crates/vtracer-py (was the deleted cmdapp/); note that manylinux builds need visioncortex 0.9.0 published to crates.io. - release.yml: note the same visioncortex prerequisite for the CLI binary.
This commit is contained in:
@@ -1,8 +1,11 @@
|
|||||||
# This file is autogenerated by maturin v1.11.5
|
# Python wheels for crates/vtracer-py (maturin). Regenerate the skeleton with:
|
||||||
# To update, run
|
# maturin generate-ci github -m crates/vtracer-py/Cargo.toml
|
||||||
#
|
|
||||||
# maturin generate-ci github
|
|
||||||
#
|
#
|
||||||
|
# PREREQUISITE: the framework depends on visioncortex 0.9.0. maturin's Linux
|
||||||
|
# builds run in manylinux containers where the local `../visioncortex` path is
|
||||||
|
# not visible, so this workflow only succeeds once visioncortex 0.9.0 is
|
||||||
|
# published to crates.io and the workspace uses the registry version (not the
|
||||||
|
# local path).
|
||||||
name: Python
|
name: Python
|
||||||
|
|
||||||
on:
|
on:
|
||||||
@@ -42,7 +45,7 @@ jobs:
|
|||||||
uses: PyO3/maturin-action@v1
|
uses: PyO3/maturin-action@v1
|
||||||
with:
|
with:
|
||||||
target: ${{ matrix.platform.target }}
|
target: ${{ matrix.platform.target }}
|
||||||
args: --release --out dist --find-interpreter --manifest-path cmdapp/Cargo.toml
|
args: --release --out dist --find-interpreter --manifest-path crates/vtracer-py/Cargo.toml
|
||||||
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
|
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
|
||||||
manylinux: auto
|
manylinux: auto
|
||||||
- name: Upload wheels
|
- name: Upload wheels
|
||||||
@@ -73,7 +76,7 @@ jobs:
|
|||||||
uses: PyO3/maturin-action@v1
|
uses: PyO3/maturin-action@v1
|
||||||
with:
|
with:
|
||||||
target: ${{ matrix.platform.target }}
|
target: ${{ matrix.platform.target }}
|
||||||
args: --release --out dist --find-interpreter --manifest-path cmdapp/Cargo.toml
|
args: --release --out dist --find-interpreter --manifest-path crates/vtracer-py/Cargo.toml
|
||||||
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
|
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
|
||||||
manylinux: musllinux_1_2
|
manylinux: musllinux_1_2
|
||||||
- name: Upload wheels
|
- name: Upload wheels
|
||||||
@@ -106,7 +109,7 @@ jobs:
|
|||||||
uses: PyO3/maturin-action@v1
|
uses: PyO3/maturin-action@v1
|
||||||
with:
|
with:
|
||||||
target: ${{ matrix.platform.target }}
|
target: ${{ matrix.platform.target }}
|
||||||
args: --release --out dist --find-interpreter --manifest-path cmdapp/Cargo.toml
|
args: --release --out dist --find-interpreter --manifest-path crates/vtracer-py/Cargo.toml
|
||||||
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
|
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
|
||||||
- name: Upload wheels
|
- name: Upload wheels
|
||||||
uses: actions/upload-artifact@v5
|
uses: actions/upload-artifact@v5
|
||||||
@@ -132,7 +135,7 @@ jobs:
|
|||||||
uses: PyO3/maturin-action@v1
|
uses: PyO3/maturin-action@v1
|
||||||
with:
|
with:
|
||||||
target: ${{ matrix.platform.target }}
|
target: ${{ matrix.platform.target }}
|
||||||
args: --release --out dist --find-interpreter --manifest-path cmdapp/Cargo.toml
|
args: --release --out dist --find-interpreter --manifest-path crates/vtracer-py/Cargo.toml
|
||||||
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
|
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
|
||||||
- name: Upload wheels
|
- name: Upload wheels
|
||||||
uses: actions/upload-artifact@v5
|
uses: actions/upload-artifact@v5
|
||||||
@@ -148,7 +151,7 @@ jobs:
|
|||||||
uses: PyO3/maturin-action@v1
|
uses: PyO3/maturin-action@v1
|
||||||
with:
|
with:
|
||||||
command: sdist
|
command: sdist
|
||||||
args: --out dist --manifest-path cmdapp/Cargo.toml
|
args: --out dist --manifest-path crates/vtracer-py/Cargo.toml
|
||||||
- name: Upload sdist
|
- name: Upload sdist
|
||||||
uses: actions/upload-artifact@v5
|
uses: actions/upload-artifact@v5
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -1,5 +1,10 @@
|
|||||||
name: Release
|
name: Release
|
||||||
|
|
||||||
|
# Builds the `vtracer` CLI binary (crates/vtracer-cli) for each target.
|
||||||
|
# PREREQUISITE: the workspace depends on visioncortex 0.9.0; this succeeds once
|
||||||
|
# 0.9.0 is published to crates.io and the workspace uses the registry version
|
||||||
|
# instead of the local `../visioncortex` path.
|
||||||
|
|
||||||
on:
|
on:
|
||||||
release:
|
release:
|
||||||
types: [published]
|
types: [published]
|
||||||
|
|||||||
@@ -12,7 +12,6 @@ on:
|
|||||||
branches:
|
branches:
|
||||||
- master
|
- master
|
||||||
- 0.*.x
|
- 0.*.x
|
||||||
- pr/**/ci
|
|
||||||
- ci-*
|
- ci-*
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
@@ -22,14 +21,62 @@ concurrency:
|
|||||||
env:
|
env:
|
||||||
CARGO_TERM_COLOR: always
|
CARGO_TERM_COLOR: always
|
||||||
|
|
||||||
|
# NOTE: the workspace depends on visioncortex 0.9.0 via a local path
|
||||||
|
# (`../visioncortex`). Until 0.9.0 is published to crates.io, CI checks out the
|
||||||
|
# visioncortex repo next to this one so the path resolves. This requires the
|
||||||
|
# 0.9.x changes to be present on visioncortex's default branch.
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
test:
|
||||||
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v4
|
||||||
- name: Build
|
with:
|
||||||
run: cargo build --verbose
|
path: vtracer
|
||||||
- name: Run tests
|
- uses: actions/checkout@v4
|
||||||
run: cargo test --verbose
|
with:
|
||||||
|
repository: visioncortex/visioncortex
|
||||||
|
path: visioncortex
|
||||||
|
- name: Build
|
||||||
|
working-directory: vtracer
|
||||||
|
run: cargo build --workspace --verbose
|
||||||
|
- name: Test
|
||||||
|
working-directory: vtracer
|
||||||
|
run: cargo test --workspace --verbose
|
||||||
|
|
||||||
|
wasm:
|
||||||
|
name: wasm-safety (core)
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
path: vtracer
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
repository: visioncortex/visioncortex
|
||||||
|
path: visioncortex
|
||||||
|
- run: rustup target add wasm32-unknown-unknown
|
||||||
|
- name: Build core for wasm32
|
||||||
|
working-directory: vtracer
|
||||||
|
run: cargo build --target wasm32-unknown-unknown -p vtracer
|
||||||
|
|
||||||
|
nodejs:
|
||||||
|
name: Node package
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
path: vtracer
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
repository: visioncortex/visioncortex
|
||||||
|
path: visioncortex
|
||||||
|
- uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: 20
|
||||||
|
- name: Install wasm-pack
|
||||||
|
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
|
||||||
|
- name: Build & test
|
||||||
|
working-directory: vtracer/nodejs
|
||||||
|
run: |
|
||||||
|
wasm-pack build --target nodejs --out-dir pkg
|
||||||
|
node test.js
|
||||||
|
|||||||
Reference in New Issue
Block a user