mirror of
https://github.com/garrytan/gstack.git
synced 2026-11-01 06:24:41 +01:00
land-and-deploy: host-neutral post-merge branch example (s06 M5)
The squash-merge cleanup example created 'codex/post-merge-pr-N' branches on every host. The example is now 'post-merge/pr-N', naming Codex Desktop's codex/ prefix as the host-specific case and keeping the detached-HEAD reason and the no-force-push rule. No test pins the removed text. expected red until the regeneration commit
This commit is contained in:
1 parent
d849689be0
commit
b38ad96a1f
1 file changed
+1
-1
@@ -116,7 +116,7 @@ Squash/rebase merge readback guard:
|
||||
git fetch "https://github.com/$REPO.git" "$BASE_BRANCH"
|
||||
git diff --quiet "$MERGE_SHA" FETCH_HEAD || git log --oneline --decorate -1 "$MERGE_SHA" FETCH_HEAD
|
||||
```
|
||||
- If the worktree is clean and only needs to stop looking diverged after a squash merge, prefer a named local branch at the merge commit, for example `git switch -c "codex/post-merge-pr-$PR_NUMBER" "$MERGE_SHA"`. Avoid detached HEAD in Codex Desktop worktrees because git action workers often expect `git symbolic-ref --short HEAD` to return a branch. Do not force-push or reset a user's branch unless they explicitly ask.
|
||||
- If the worktree is clean and only needs to stop looking diverged after a squash merge, prefer a named local branch at the merge commit over a detached HEAD, for example `git switch -c "post-merge/pr-$PR_NUMBER" "$MERGE_SHA"` (use the host's branch prefix where it has one, such as `codex/` in Codex Desktop, whose git action workers expect `git symbolic-ref --short HEAD` to return a branch). Do not force-push or reset a user's branch unless they explicitly ask.
|
||||
|
||||
Worktree cleanup — non-destructive, candidate-based:
|
||||
```bash
|
||||
|
||||
Reference in new issue
Block a user