-
Notifications
You must be signed in to change notification settings - Fork 0
94 lines (74 loc) · 3.03 KB
/
Copy pathci.yml
File metadata and controls
94 lines (74 loc) · 3.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
# Cancel in-progress runs on the same branch so a fast follow-up commit
# doesn't queue behind a stale one.
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
env:
PNPM_VERSION: '10'
NODE_VERSION: '22'
jobs:
check:
name: Check (macOS Apple Silicon)
runs-on: macos-14
steps:
# ── Checkout + toolchains ─────────────────────────────────────────────
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt, clippy
- uses: swatinem/rust-cache@v2
with:
workspaces: ". -> target"
cache-on-failure: true
- uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
- uses: pnpm/action-setup@v4
with:
version: ${{ env.PNPM_VERSION }}
# ── Rust checks ───────────────────────────────────────────────────────
- name: cargo fmt
run: cargo fmt --all --check
- name: cargo clippy
# Exclude the Tauri app: its build script requires sidecar binaries
# that only exist after `build-sidecar.sh` runs (release pipeline only).
run: cargo clippy --workspace --all-targets --exclude Lumen -- -D warnings
- name: cargo test (lumen-core)
run: cargo test -p lumen-core
# ── Frontend build ───────────────────────────────────────────────────
# Verifies the Angular build compiles clean; catches template errors
# and TypeScript issues before they block a release.
- name: pnpm install
working-directory: lumenator
run: pnpm install --frozen-lockfile
- name: pnpm build
working-directory: lumenator
run: pnpm build
# ── Cross-platform CLI/core job: Linux + Windows ───────────────────────────
# The `lumen` CLI and the core/daemon/mcp crates are pure cross-platform Rust.
# SQLite is compiled from source (rusqlite `bundled`), so no system libsqlite3
# is needed on any OS. The Tauri GUI is macOS-only and lives in the check job.
test:
name: Test (${{ matrix.os }})
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: swatinem/rust-cache@v2
with:
workspaces: ". -> target"
cache-on-failure: true
- name: Build CLI (proves cross-platform compile)
run: cargo build -p lumen-cli --release
- name: cargo test (core + daemon + mcp)
run: cargo test -p lumen-core -p lumen-daemon -p lumen-mcp