文档:集成本地构建发布契约

This commit is contained in:
2026-08-12 21:27:51 +08:00
parent 5b44864265
commit 6e822ccf7c
14 changed files with 156 additions and 36 deletions

View File

@@ -6,12 +6,17 @@
## Task Completion Standard
- {condition that means a task is complete}
- 可发布小游戏/小程序的一键提交必须由 Electron Main 对安全源码快照执行固定 npm 11.6.2 的 `npm ci --ignore-scripts`,并调用项目 `package-lock.json` 锁定的 Vite 生成静态产物。
- Electron 双视口预检必须检查与最终 `built_archive` 相同的内存文件字节;预检失败不得上传,预检成功不得被表述为可信审核凭据。
- 上传协议必须同时携带源码归档、构建归档和严格版本化 artifact contract服务端独立重算摘要、校验合同并固化不可变 Release。
- Renderer 不得获得发布凭据、归档、临时目录、构建 origin 或任意本地路径;旧客户端和旧 sandbox/browser 任务必须提示升级后重新构建提交。
## Quality Checks
- {verification command, review expectation, or acceptance check}
- 发布安装包前运行 `pnpm verify:publish-runtime`,并对最终 Windows 产物运行 `pnpm verify:artifact:win`;固定 npm 闭包缺失或版本不符时 fail closed。
- 至少覆盖 release builder/静态产物服务/发布路由/Renderer 状态的聚焦测试、typecheck、scoped lint、Vite 构建和真实 Electron 双视口 production-seam E2E。
- 真实生产发布仍需成组验证服务端合同、不可变 Release、运营审核、CDN/App 播放;客户端本地验证不能替代该整链验收。
## Last Reviewed
{YYYY-MM-DD}
2026-08-12