- release.cjs:assertNoDowngrade 的通道探测原先对网络错误/5xx/解析失败 一律放行(fail-open),旧分支发旧版本号撞上探测失败会覆盖 latest.yml 并让 pruneChannel 删掉线上更新版本的 exe。现仅通道真空(404)放行, 其余抛错中止发布;prune 前的探测保持 best-effort - 新增 --skip-gitea-release(只跳 Gitea release、通道照常上传); --skip-gitea 保持原行为但打印醒目警告;usage 补全 flag 语义 - 文档对齐:STATE.md(v1.0.23、19→22 离线测试、清除 MSI 描述、bundle 清单补全)、ROADMAP 补 M12/M13、ci.yml 与 AGENTS.md 测试计数、 AGENTS.md 补录本轮关键不变式(legacy 模板门控、SESSION_STATE/ pendingOpens、zmodem 背压钩子、主机密钥 TTL);.gitignore 清重复与 死条目
47 lines
1.2 KiB
YAML
47 lines
1.2 KiB
YAML
name: CI
|
||
|
||
on:
|
||
push:
|
||
pull_request:
|
||
|
||
permissions:
|
||
contents: read
|
||
|
||
concurrency:
|
||
group: ci-${{ github.ref }}
|
||
cancel-in-progress: true
|
||
|
||
jobs:
|
||
verify:
|
||
name: typecheck + test + build (windows)
|
||
runs-on: windows-latest
|
||
timeout-minutes: 30
|
||
steps:
|
||
- uses: actions/checkout@v4
|
||
|
||
- uses: actions/setup-node@v4
|
||
with:
|
||
node-version: 22
|
||
cache: npm
|
||
|
||
# `npm ci` triggers electron's postinstall, which downloads the ~100MB
|
||
# binary into %LOCALAPPDATA%\electron\Cache. Keyed on the lockfile so any
|
||
# dependency bump — electron included — refetches instead of restoring a
|
||
# binary that no longer matches the pinned version.
|
||
- name: Cache Electron binary
|
||
uses: actions/cache@v4
|
||
with:
|
||
path: ~/AppData/Local/electron/Cache
|
||
key: electron-${{ runner.os }}-${{ hashFiles('package-lock.json') }}
|
||
|
||
- name: Install dependencies
|
||
run: npm ci
|
||
|
||
# npm test 会先自动跑 pretest(typecheck),再重建 esbuild bundle 并跑 19 个离线测试
|
||
- name: Test
|
||
run: npm test
|
||
|
||
# 仅验证构建通过;不做 electron-builder 打包、不发布、不传 artifact
|
||
- name: Build
|
||
run: npm run build
|