Repository navigation
fix(bin): avoid duplicating task text in Herdr safety gates - #11
Merged
Merged
Conversation
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Intent
Fix bin/fm-brief.sh so its generated scaffolds contain the {TASK} placeholder token exactly once. The Herdr lifecycle declaration's HARD SAFETY GATE prose contained a literal {TASK} token, so filling every {TASK} (per AGENTS.md section 11) pasted the whole task into the middle of the safety gate; ship and scout scaffolds were affected. Reword it to refer to the task placeholder above without the literal token, preserving the gate meaning (scaffold cannot inspect the task text; regenerate with --herdr-lab). Secondmate charters intentionally keep two placeholders (charter and routing scope), so they are unchanged. Do not edit AGENTS.md. Test through the executable: extend tests/fm-brief.test.sh to generate each variant into its own distinct isolated FM_HOME, assert exactly one {TASK} token in ship/scout output, and fill every {TASK} with a unique marker asserting it appears once with the gate sentence intact; never assert script source bytes. PR must target the fork Hozzy02/firstmate, not upstream kunchenguid/firstmate. Standards: shellcheck via bin/fm-lint.sh; never add an agent name as a commit co-author (no Co-Authored-By footer on any commit).
What Changed
{TASK}placeholder without changing the gate’s meaning or--herdr-labguidance.FM_HOMEdirectories, including filled-marker assertions and the intentional two-placeholder secondmate behavior.Risk Assessment
✅ Low: The narrowly scoped prose fix preserves the Herdr safety gate, and executable-level coverage enforces the token-count invariant across ship, scout, Herdr-lab, and intentionally distinct secondmate variants.
Testing
The focused executable test passed before and after the test-only correction; end-to-end generation proved all ship/scout variants contain and fill exactly one task placeholder while secondmate retains two, with the Herdr gate intact. CLI transcript and generated-scaffold artifacts were captured; no visual screenshot applies to this non-UI change. Lint was not run because this assigned test phase explicitly prohibits linters and the outer executor owns the lint phase.
Evidence: End-to-end scaffold evidence
Ship and scout variants each contained one placeholder and one filled marker; secondmate retained two. Herdr safety-gate wording and--herdr-labdirection remained intact.Evidence: Filled no-mistakes ship scaffold
Evidence: Filled scout scaffold
Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
✅ **Review** - passed
✅ No issues found.
✅ **Test** - passed
✅ No issues found.
Inspectedgit diff d67249367f8d1d843df7ea53d496be20095724d4..8dafd02f4e7fd28961ea7ff2c69dfbaf101ddca7 -- bin/fm-brief.sh tests/fm-brief.test.sh.Ranbash tests/fm-brief.test.shbefore and after the focused test correction.Generated seven variants throughbin/fm-brief.sh, each with a distinct isolatedFM_HOME; replaced every{TASK}with a unique marker and verified counts plus emitted gate wording.Rangit remote -v, inspected changed paths, and searched target-branch commit messages forCo-Authored-By:footers.✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.