Skip to content

emrg: build-release 十三次修复 — Windows gh.exe 解压探测(rant #13) - #381

Merged
argszero merged 1 commit into
masterfrom
feature/build-release-fixes13
Aug 4, 2026
Merged

emrg: build-release 十三次修复 — Windows gh.exe 解压探测(rant #13)#381
argszero merged 1 commit into
masterfrom
feature/build-release-fixes13

Conversation

@argszero

@argszero argszero commented Aug 4, 2026

Copy link
Copy Markdown
Owner

第 13 次实跑:3/4 平台成功,Windows build-runtime 已通过(DLL 修复生效,runtime built OK 89M),新失败在 bundle-git-gh.sh:chmod: cannot access '.../bin/gh'

根因:Windows gh zip 内可执行文件名为 gh.exe(不是 gh)。原 find "$TMP" -name gh -type f 在 Windows 找不到 → xargs 不执行 → $RUNTIME/bin/gh 不存在 → chmod exit 1。且 Windows 目标名需为 gh.exe(PATH 注入后命令解析需要 .exe)。

修复

  1. find 同时探测 gh 与 gh.exe
  2. 目标名按平台:windows → bin/gh.exe,其他 → bin/gh
  3. 找不到可执行文件时显式报错退出

验证

  • bash -n OK
  • Windows(gh.exe → 目标 gh.exe)/ POSIX(gh → 目标 gh)逻辑正确
  • pytest 464 passed;import checks OK

背景:rant #13 Phase 4 发布期。合并后重打 tag 第 14 次实跑,预期 4/4 全绿 → Release 发布。

第 13 次实跑:3/4 平台成功,Windows build-runtime 已通过(DLL 修复生效,
runtime built OK 89M),新失败在 bundle-git-gh.sh:chmod bin/gh 失败。

根因:Windows gh zip 内可执行文件名为 gh.exe(不是 gh)。第 60 行
`find  -name gh -type f` 在 Windows 找不到 → xargs 不执行 →
/bin/gh 不存在 → chmod exit 1。且 Windows 目标名需为 gh.exe
(PATH 注入后命令解析需要 .exe)。

修复:find 同时探测 gh 与 gh.exe;目标名按平台——windows → bin/gh.exe,
其他 → bin/gh;找不到可执行文件时显式报错退出。

验证:
- bash -n OK
- Windows(gh.exe 存在 → 目标 gh.exe)/ POSIX(gh → 目标 gh)逻辑正确
- pytest 464 passed;import checks OK

@argszero argszero left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle 20260805-0070

审查内容:bundle-git-gh.sh Windows gh.exe 探测——find 同时匹配 gh/gh.exe,目标名按平台(windows→gh.exe)。修复第 13 次实跑 chmod bin/gh 失败。

验证:bash -n OK;Windows/POSIX 逻辑模拟正确;pytest 464 passed。根因分析准确(Windows zip 内 gh.exe)。

@argszero argszero left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle 20260805-0071

第二次复核:diff 与上轮一致(bundle-git-gh.sh find 探测 gh/gh.exe + 目标名按平台)。bash -n OK;逻辑模拟正确。无新增问题。

@argszero argszero left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle 20260805-0072

第三次复核:diff 稳定(bundle-git-gh.sh find 探测 gh/gh.exe + 目标名按平台 windows→gh.exe)。bash -n OK;逻辑模拟正确;pytest 464 passed。3 个不同 cycle(0070/0071/0072)连续 LGTM,满足合并条件。

@argszero
argszero merged commit 1196065 into master Aug 4, 2026
1 check passed
@argszero
argszero deleted the feature/build-release-fixes13 branch August 5, 2026 06:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant