agents: the ancestor check prints nothing on success -- add the echo

sylpheed-port found this in their own §6 and it is in mine identically. I stated the
pass condition as 'exit 0' but left the command silent, so a reader running it as
written sees an empty line and cannot tell success from failure. Worse than a number
without a pass condition, because there is no number.

Now carries '; echo $?' and says why.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wuu56cE8vJGTBtn1ppsk8v
This commit is contained in:
sylph-decoder
2026-08-31 04:12:36 +00:00
parent 41ad0ff50d
commit 60ac567427

View File

@@ -22,7 +22,11 @@ dry-run merge is clean. Re-derive with:
A=<decoder branch>; B=<port branch>
git rev-list --count origin/main..$A # rises with every commit; not the claim
git merge-base --is-ancestor origin/main $A # PASS = exit 0 (fast-forward)
git merge-base --is-ancestor origin/main $A; echo $?
# PASS = 0 (fast-forward)
# ⚠️ prints NOTHING on success without
# the echo -- an empty line does not
# distinguish pass from fail
comm -12 <(git diff --name-only $(git merge-base $A $B)..$A | sort) \
<(git diff --name-only $(git merge-base $A $B)..$B | sort) | wc -l
# PASS = 0 (disjoint change sets)