-
Notifications
You must be signed in to change notification settings - Fork 0
89 lines (69 loc) · 1.81 KB
/
Copy pathnode-ci.yml
File metadata and controls
89 lines (69 loc) · 1.81 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
name: Node CI
on:
push:
branches: [main, master]
pull_request:
jobs:
build-test:
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "22"
cache: npm
- name: Install dependencies
run: npm ci
- name: Lint
run: npm run lint
- name: Prettier (check)
run: npm run format:check
- name: Typecheck
run: npm run typecheck
- name: Build
run: npm run build
- name: Test with coverage gate
run: npm run test:coverage
- name: Production dependency audit
run: npm audit --omit=dev --audit-level=high
docker-smoke:
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Build Docker image
run: docker build -t specsync:ci .
- name: Smoke — image has compiled entrypoint
run: |
docker run --rm --entrypoint node specsync:ci -e "require('fs').accessSync('dist/index.js')"
vscode-extension:
runs-on: ubuntu-latest
permissions:
contents: read
defaults:
run:
working-directory: vscode-extension
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "22"
cache: npm
cache-dependency-path: vscode-extension/package-lock.json
- name: Install extension deps
run: |
if [ -f package-lock.json ]; then
npm ci
else
npm install
fi
- name: Compile extension
run: npm run compile