Skip to content

Commit f26eca5

Browse files
jsvdclaude
andcommitted
Add crates.io publish job to CI, triggered on version tags
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent e45ef0c commit f26eca5

1 file changed

Lines changed: 25 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ name: CI
33
on:
44
push:
55
branches: [main]
6+
tags: ["v*"]
67
pull_request:
78
branches: [main]
89

@@ -93,3 +94,27 @@ jobs:
9394
- name: Install system dependencies (ALSA + udev)
9495
run: sudo apt-get update && sudo apt-get install -y libasound2-dev libudev-dev
9596
- run: cargo check --workspace
97+
98+
publish:
99+
name: Publish to crates.io
100+
if: startsWith(github.ref, 'refs/tags/v')
101+
needs: [ts-tests-node, rust-tests, ts-tests-v8, headless-check, declarations-check, full-build]
102+
runs-on: ubuntu-latest
103+
steps:
104+
- uses: actions/checkout@v4
105+
- uses: dtolnay/rust-toolchain@stable
106+
- uses: Swatinem/rust-cache@v2
107+
with:
108+
prefix-key: v1-rust
109+
- name: Install system dependencies (ALSA + udev)
110+
run: sudo apt-get update && sudo apt-get install -y libasound2-dev libudev-dev
111+
- name: Publish arcane-core
112+
run: cargo publish -p arcane-core
113+
env:
114+
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
115+
- name: Wait for crates.io indexing
116+
run: sleep 60
117+
- name: Publish arcane-engine
118+
run: cargo publish -p arcane-engine --allow-dirty
119+
env:
120+
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}

0 commit comments

Comments
 (0)