Repository navigation
ci: 精简纯文档检查并降低打包压缩耗时 #100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
ci: 精简纯文档检查并降低打包压缩耗时 #100
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
bd86d96
ci: streamline documentation checks and package compression
Dailin521 d1791b9
fix(ci): support Node 16 fixtures and validate documentation destinat…
Dailin521 9be5cea
fix(ci): align docs-only contracts and rendered link validation
Dailin521 e765899
fix(ci): ignore footnote prose and indented code examples
Dailin521 2a55ab4
test: isolate cross-runtime process lock fixtures
Dailin521 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| # CI 与打包提速记录 | ||
|
|
||
| ## 本次范围 | ||
|
|
||
| - 普通文档 PR 使用白名单轻量检查,规则见 [Windows 发布流程](WINDOWS_ELECTRON_RELEASE_ZH.md)。按整个 PR 判断,代码 PR 后续只补文档仍完整检查。 | ||
| - 同一 PR 新提交取消旧运行;main 和独立发布运行保留。 | ||
| - electron-builder 使用 `compression: normal`,保留原包大小限制、产物审计和容器验收。 | ||
| - main 最终源码的跨平台检查与发布门禁不变。RC 与正式更新渠道的产物复用、不稳定测试诊断留待后续处理。 | ||
|
|
||
| ## Windows ZIP 压缩实测 | ||
|
|
||
| 2026-09-11,在同一台 Windows 开发机上,使用锁定的 electron-builder 26.15.7 内部 `archive('zip', ..., { compression, withoutDir: true, preserveSymlinks: false })`,对同一份本地 1.0.2 程序内容分别压缩一次。未设置压缩级别环境变量。该测量用于选择压缩配置,不是新源码的正式发布证据;测试期间机器也执行了其他验证,不能据此承诺 CI 的固定耗时。 | ||
|
|
||
| | 配置 | 耗时 | ZIP 字节数 | | ||
| | --- | ---: | ---: | | ||
| | maximum | 310.14 秒 | 128,959,840 | | ||
| | normal | 42.48 秒 | 129,224,083 | | ||
|
|
||
| 本次测量耗时下降约 86%,大小增加 264,243 字节(约 258 KiB,0.20%)。普通压缩 ZIP 低于现有 130 MiB 上限。该版本打包器的 maximum ZIP 使用 `-mx=9 -mfb=258 -mpass=15`,normal 使用 `-mx=7`。 | ||
|
|
||
| 两份 ZIP 解压后的 18 个文件逐个 SHA-256 相同。共同的 `resources/app.asar` SHA-256:`914b88f24d954c1ad9a2f5e4db82f1c52b9db67bfa9020e7e36efacf82e7ee9e`。 | ||
|
|
||
| normal ZIP 解压后的生产包 4 项测试通过,包含真实公开更新检查、SQLite、Provider 切换、隔离数据 Sync → Restore。普通压缩 NSIS 通过 prepackaged 构建,大小 104,601,532 字节,低于 105 MiB 上限;未在本机执行实际安装/卸载。macOS/Linux 新压缩配置和真实安装验收仍需后续 CI 验证。 | ||
|
|
||
| 复测时使用固定输入目录及新的输出路径,记录打包器版本、源文件哈希、环境变量、耗时、大小及解压后的逐文件哈希。不要复用已存在 ZIP,以免打包器按时间戳跳过压缩;不要放宽包大小限制来使测量通过。 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.