-
Notifications
You must be signed in to change notification settings - Fork 5
77 lines (74 loc) · 2.66 KB
/
Copy pathci.yml
File metadata and controls
77 lines (74 loc) · 2.66 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
name: CI
on:
push:
branches: [main, master, feature/**]
pull_request:
branches: [main, master, feature/**]
jobs:
sdk:
runs-on: ${{ (startsWith(vars.CI_RUNNER, 'blacksmith-') && vars.CI_RUNNER) || 'blacksmith-4vcpu-ubuntu-2404' }}
strategy:
fail-fast: false
matrix:
node-version: [20, 22, 24]
defaults:
run:
working-directory: sdks/typescript-sdk
steps:
- uses: useblacksmith/checkout@v1
- uses: actions/setup-node@v6
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
cache-dependency-path: sdks/typescript-sdk/package-lock.json
- name: Install SDK deps
run: npm ci
- name: Build SDK
run: npm run build
- name: Type-check SDK
run: npm run type-check
- name: Generate SDK docs
if: matrix.node-version == 24
run: npm run docs
- name: Check generated SDK docs are up to date
if: matrix.node-version == 24
working-directory: ${{ github.workspace }}
run: |
git diff --exit-code -- docs/sdk/reference
test -z "$(git status --porcelain -- docs/sdk/reference)"
- name: Test SDK
run: npm test -- --run
# oxlint/oxfmt require Node 20+; lint is static so it only needs one
# modern runtime. Build/test still cover the full matrix for consumers.
- name: Lint SDK (oxlint + oxfmt)
if: matrix.node-version == 24
run: npm run lint
mcp:
runs-on: ${{ (startsWith(vars.CI_RUNNER, 'blacksmith-') && vars.CI_RUNNER) || 'blacksmith-4vcpu-ubuntu-2404' }}
steps:
- uses: useblacksmith/checkout@v1
- uses: actions/setup-node@v6
with:
node-version: 24
cache: 'npm'
cache-dependency-path: package-lock.json
- name: Install MCP deps (published SDK)
run: npm ci
- name: Build SDK (workspace dependency)
run: npm run build --workspace @terminal49/sdk
- name: Build MCP
run: npm run build --workspace @terminal49/mcp
- name: Type-check SDK + MCP
run: |
npm run type-check --workspace @terminal49/sdk
npm run type-check --workspace @terminal49/mcp
- name: Type-check MCP eval suite
run: npm run eval:check --workspace @terminal49/mcp
- name: Test MCP
run: npm run test --workspace @terminal49/mcp -- --run --coverage
- name: Eval MCP tools (live; skips without MCP_EVAL_TOKEN secret)
env:
MCP_EVAL_TOKEN: ${{ secrets.MCP_EVAL_TOKEN }}
run: npm run eval --workspace @terminal49/mcp
- name: Lint MCP (oxlint + oxfmt)
run: npm run lint --workspace @terminal49/mcp