-
Notifications
You must be signed in to change notification settings - Fork 10
162 lines (131 loc) · 5.1 KB
/
Copy pathchecks.yaml
File metadata and controls
162 lines (131 loc) · 5.1 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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
name: Checks
on:
push:
branches: [dev]
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: "25.2.1"
cache: "npm"
- name: Install dependencies
run: npm ci
- name: Lint
run: npm run lint
continue-on-error: true
- name: Typecheck
run: npx prisma generate && npx tsc --noEmit
build-macos:
runs-on: macos-latest
steps:
- uses: actions/checkout@v6
- name: Setup desktop build toolchain
uses: ./.github/actions/setup-desktop-build
with:
platform: macos
- name: Build macOS bundle
run: npm run build:macos
build-windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v6
- name: Setup desktop build toolchain
uses: ./.github/actions/setup-desktop-build
with:
platform: windows
- name: Build MSIX bundle
run: npm run build:windows
build-docker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Build Docker image
run: docker compose build app-prod
benchmark:
runs-on: ubuntu-latest
strategy:
matrix:
browser: [chromium, webkit]
steps:
- uses: actions/checkout@v6
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: "25.2.1"
cache: "npm"
- name: Install dependencies
run: npm ci
- name: Get Playwright version
id: pw-version
run: echo "version=$(node -e "console.log(require('./node_modules/playwright-core/package.json').version)")" >> $GITHUB_OUTPUT
- name: Cache Playwright browser
uses: actions/cache@v4
id: pw-cache
with:
path: ~/.cache/ms-playwright
key: playwright-${{ matrix.browser }}-${{ steps.pw-version.outputs.version }}
- name: Install Playwright browser and system deps
if: steps.pw-cache.outputs.cache-hit != 'true'
run: npx playwright install --with-deps ${{ matrix.browser }}
- name: Install Playwright system deps only
if: steps.pw-cache.outputs.cache-hit == 'true'
run: npx playwright install-deps ${{ matrix.browser }}
- name: Run benchmarks
run: npx vitest bench --project ${{ matrix.browser }}
- name: Upload benchmark results
uses: actions/upload-artifact@v4
with:
name: bench-results-${{ matrix.browser }}
path: bench-results.json
retention-days: 90
overwrite: true
benchmark-compare:
runs-on: ubuntu-latest
needs: benchmark
steps:
- uses: actions/checkout@v6
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: "25.2.1"
cache: "npm"
- name: Download chromium results
uses: actions/download-artifact@v4
with:
name: bench-results-chromium
path: bench-current-chromium
- name: Download webkit results
uses: actions/download-artifact@v4
with:
name: bench-results-webkit
path: bench-current-webkit
- name: Merge current results
run: node scripts/merge-bench.mjs bench-current-chromium/bench-results.json bench-current-webkit/bench-results.json > bench-results.json
- name: Download previous benchmark baseline
uses: dawidd6/action-download-artifact@v9
continue-on-error: true
with:
name: bench-results
path: bench-baseline
workflow: checks.yaml
branch: ${{ github.ref_name }}
if_no_artifact_found: warn
- name: Compare and report
run: |
if [ -f bench-baseline/bench-results.json ]; then
node scripts/compare-bench.mjs bench-baseline/bench-results.json bench-results.json >> $GITHUB_STEP_SUMMARY
else
echo "<h2>Benchmark Results</h2><p>No baseline found — results uploaded as the new baseline.</p>" >> $GITHUB_STEP_SUMMARY
fi
continue-on-error: true
- name: Upload merged benchmark results as new baseline
uses: actions/upload-artifact@v4
with:
name: bench-results
path: bench-results.json
retention-days: 90
overwrite: true