fix: extend fix-slash-commands SEARCH_DIRS to agents/, sdk/src/, .clinerules

scripts/fix-slash-commands.cjs SEARCH_DIRS did not cover agents/, sdk/src/,
or top-level files, so 9 colon-form references survived in 6 files. The hit
at agents/gsd-codebase-mapper.md:105 propagated into ~/.claude/agents/ at
install time (the fixer is not wired into install) and produced unrunnable
/gsd:<cmd> suggestions in agent output on non-Gemini runtimes.

This commit includes Pass 1 (the 9 line edits) AND Pass 2 (extending the
fixer's SEARCH_DIRS so future regressions are auto-rewritten and caught by
the bug-2543 guard, which mirrors that list). The standalone bug-3100 test
added in the prior revision is removed in favor of the bug-2543 guard's
extended scan, per CONTRIBUTING.md test standards (no source-grep tests on
non-.md files).

Refs #3100
This commit is contained in:
Patrick Clery
2026-05-04 15:42:35 -04:00
committed by Test
parent 42ed7cee8d
commit f9c1f01971
9 changed files with 75 additions and 22 deletions

View File

@@ -1128,7 +1128,7 @@ export const statePlannedPhase: QueryHandler = async (args, projectDir, workstre
* Query handler for `state.milestone-switch` — resets STATE.md for a new
* milestone cycle (bug #2630 regression guard).
*
* The `/gsd:new-milestone` workflow only rewrote STATE.md's body (Current
* The `/gsd-new-milestone` workflow only rewrote STATE.md's body (Current
* Position section). The YAML frontmatter (`milestone`, `milestone_name`,
* `status`, `progress.*`) was never touched on a mid-flight switch, so queries
* that read frontmatter (`state.json`, `getMilestoneInfo`, every handler that
@@ -1151,7 +1151,7 @@ export const statePlannedPhase: QueryHandler = async (args, projectDir, workstre
*
* Sibling CJS parity: `cmdInitNewMilestone` in `init.cjs` is read-only (like
* the TS `initNewMilestone`). The workflow-level fix is to call
* `state.milestone-switch` from `/gsd:new-milestone` Step 5 in place of the
* `state.milestone-switch` from `/gsd-new-milestone` Step 5 in place of the
* manual body rewrite.
*/
export const stateMilestoneSwitch: QueryHandler = async (args, projectDir, workstream) => {

View File

@@ -649,7 +649,7 @@ export const verifySchemaDrift: QueryHandler = async (args, projectDir, workstre
*
* Non-blocking by contract: every failure mode returns a successful response
* with `{ skipped: true, reason }`. The post-execute drift gate in
* `/gsd:execute-phase` relies on this guarantee.
* `/gsd-execute-phase` relies on this guarantee.
*
* Delegates to the Node-side implementation in `bin/lib/drift.cjs` and
* `bin/lib/verify.cjs` via a child process so the drift logic stays in one