Fix gstack build when Conductor creates a repo with unborn HEAD#1177
Fix gstack build when Conductor creates a repo with unborn HEAD#1177Cloverings1 wants to merge 1 commit intogarrytan:mainfrom
Conversation
|
Additional verification after reproducing this locally through Conductor:
I also tested the PR rebased onto current
So the fix still preserves normal commit SHA behavior while allowing Conductor/new-repo bootstrap flows to finish before the first commit exists. |
be8516c to
2462742
Compare
|
Updated this PR against current It now keeps the current I also added regression coverage for both observed bootstrap failure modes:
Focused validation passes locally: bun test test/write-build-version.test.ts test/setup-codesign.test.ts
# 9 pass, 0 failI tried a full |
This PR fixes a Conductor Quick Start failure where the gstack template build exits with code 128 before the generated repo has an initial commit.
Root cause: the build script calls git rev-parse HEAD while the repo can still have an unborn HEAD. That makes setup fail even though the upstream gstack repo itself has a valid HEAD.
Changes:
Adds scripts/write-build-version.sh
Falls back to unknown when HEAD does not resolve
Writes the resolved version to all .version files
Adds regression coverage for both unborn HEAD and normal committed repos