-
Notifications
You must be signed in to change notification settings - Fork 1
39 lines (37 loc) · 1.5 KB
/
Copy pathtypecheck.yml
File metadata and controls
39 lines (37 loc) · 1.5 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
# The type gate. There is no test suite in this repo to run.
#
# Until MX-222 this repo's only CI job was `managed-install`, which proves the
# plugin BUILDS from a git install and says nothing about whether it works:
# `bb plugin build` bundles WITHOUT typechecking, so a type error anywhere in
# server.ts (34k) or app.tsx still produced a green check.
#
# This is a SEPARATE job rather than more steps on managed-install, because
# that job installs `--omit=dev` — typescript and @types/* are absent by the
# time it ends.
#
# What a green run here covers: `tsc --noEmit` under `strict` with
# `skipLibCheck: false`, over server.ts, app.tsx, components, lib, hooks and
# types. What it does NOT cover: whether any of it WORKS. Green means it
# compiles — MX-835 was a type-correct `undefined` that bb's RPC serialiser
# refused at runtime, and it passed this job. Execution lives in the sibling
# `Test` job (.github/workflows/test.yml), which covers lib/ only.
name: Typecheck
on:
pull_request:
push:
branches: [main, main-public]
workflow_dispatch:
jobs:
typecheck:
name: tsc --noEmit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "22"
# `npm ci` rather than `npm install`: it installs the lockfile exactly and
# fails when package.json and package-lock.json disagree, so CI checks the
# tree a fresh clone would get.
- run: npm ci --no-audit --no-fund
- run: npm run typecheck