fix(integrations): Forge dispatches hyphenated /speckit-<cmd> invocations#3529
Open
jawwad-ali wants to merge 1 commit into
Open
fix(integrations): Forge dispatches hyphenated /speckit-<cmd> invocations#3529jawwad-ali wants to merge 1 commit into
jawwad-ali wants to merge 1 commit into
Conversation
…ions Forge installs its slash-commands with hyphenated names (speckit-foo-bar, via format_forge_command_name and the injected frontmatter name), but ForgeIntegration inherited MarkdownIntegration.build_command_invocation, which builds the dotted /speckit.<cmd>. So 'workflow'/command dispatch invoked /speckit.plan while the registered command is /speckit-plan — a name Forge never registered. Override build_command_invocation to reuse format_forge_command_name, producing /speckit-<name> (with '.'-to-'-' for extension commands), mirroring the skills agents' hyphenated invocation. Tests assert Forge core + extension invocations are hyphenated, incl. args (fail before: dotted /speckit.plan / /speckit.git.commit). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
What
Forge installs its slash-commands with hyphenated names —
speckit-plan,speckit-git-commit— viaformat_forge_command_nameand the injected frontmattername(done for ZSH/shell compatibility, as the module docstring notes).But
ForgeIntegrationinheritsMarkdownIntegration.build_command_invocation, which builds the dotted form:So command/workflow dispatch invokes
/speckit.planwhile the registered Forge command is/speckit-plan— a name Forge never registered.Fix
Override
build_command_invocationinForgeIntegrationto reuse the module's ownformat_forge_command_name, producing/speckit-<name>(with.→-for extension commands likespeckit.git.commit→/speckit-git-commit). This mirrors the skills agents' hyphenatedbuild_command_invocationand Forge's own installed naming.Test
test_forge_core_command_hyphenated/test_forge_extension_command_hyphenatedassert Forge invocations are hyphenated (incl. args) — fail before (dotted/speckit.plan,/speckit.git.commit), pass after.🤖 Written with the assistance of Claude Code (AI). Bug self-found; fix/tests verified locally (fail-before / pass-after), ruff clean.