-
Notifications
You must be signed in to change notification settings - Fork 0
70 lines (66 loc) · 1.93 KB
/
Copy pathci.yml
File metadata and controls
70 lines (66 loc) · 1.93 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
name: CI
on:
push:
branches: [main]
pull_request:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v5
with:
node-version: '20'
cache: 'npm'
# Lockfile is in sync, so `npm ci` enforces it (reproducible installs).
- run: npm ci
- name: Unit tests
run: npm test
- name: Lint
run: npm run lint
# Blocking: catches structural HTML errors (e.g. an unescaped " that
# terminates an attribute) that node --check + vitest + eslint can't see.
- name: HTML parse check
run: npm run check:html
- name: Format check
run: npm run format:check
- name: Dependency audit
run: npm audit --audit-level=high
mcp:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v5
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: mcp/package-lock.json
- run: npm ci
working-directory: mcp
- name: MCP syntax check
run: find . -maxdepth 1 -name '*.js' -print0 | xargs -0 -n1 node --check
working-directory: mcp
- name: MCP dependency audit
run: npm audit --audit-level=moderate
working-directory: mcp
website:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v5
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: website/package-lock.json
- run: npm ci
working-directory: website
- name: Website lint
run: npm run lint
working-directory: website
- name: Website build
run: npm run build
working-directory: website
- name: Website dependency audit (advisory)
run: npm audit --audit-level=moderate
working-directory: website
continue-on-error: true