-
Notifications
You must be signed in to change notification settings - Fork 0
90 lines (86 loc) · 3 KB
/
ci.yml
File metadata and controls
90 lines (86 loc) · 3 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
name: CI
on:
push:
branches: [main, develop]
pull_request:
jobs:
root-checks:
name: Root checks (Biome + Prettier)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v4
with:
node-version-file: .nvmrc
cache: pnpm
- run: pnpm install --frozen-lockfile
- run: pnpm ci:check
changes:
name: Detect changed packages
runs-on: ubuntu-latest
outputs:
pr-review: ${{ steps.filter.outputs.pr-review }}
auto-format: ${{ steps.filter.outputs.auto-format }}
confluence-publish: ${{ steps.filter.outputs.confluence-publish }}
release-tools: ${{ steps.filter.outputs.release-tools }}
unic-archon-dlc: ${{ steps.filter.outputs.unic-archon-dlc }}
steps:
- uses: actions/checkout@v4
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
pr-review:
- 'apps/claude-code/pr-review/**'
auto-format:
- 'apps/claude-code/auto-format/**'
unic-confluence:
- 'apps/claude-code/unic-confluence/**'
release-tools:
- 'packages/release-tools/**'
unic-archon-dlc:
- 'apps/claude-code/unic-archon-dlc/**'
test:
name: Test ${{ matrix.package }} / ${{ matrix.os }} / Node ${{ matrix.node }}
needs: changes
if: |
needs.changes.outputs.auto-format == 'true' ||
needs.changes.outputs.unic-confluence == 'true' ||
needs.changes.outputs.release-tools == 'true' ||
needs.changes.outputs.unic-archon-dlc == 'true'
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
node: ['22', '24']
package:
- name: auto-format
changed: ${{ needs.changes.outputs.auto-format }}
- name: unic-confluence
changed: ${{ needs.changes.outputs.unic-confluence }}
- name: release-tools
changed: ${{ needs.changes.outputs.release-tools }}
- name: unic-archon-dlc
changed: ${{ needs.changes.outputs.unic-archon-dlc }}
exclude:
- package:
changed: 'false'
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # verify:changelog needs full history to diff against base branch
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}
cache: pnpm
- if: runner.os != 'Windows'
run: pnpm install --frozen-lockfile
- if: runner.os == 'Windows'
run: pnpm install --frozen-lockfile --ignore-scripts
- run: pnpm --filter ${{ matrix.package.name }} --if-present test
- run: pnpm --filter ${{ matrix.package.name }} --if-present typecheck
- if: github.event_name == 'pull_request'
run: pnpm --filter ${{ matrix.package.name }} --if-present verify:changelog