A Claude Code slash command for fixing bugs using TDD workflow.
# Clone to your preferred location
git clone git@github.com:claude-commands/command-fix-issue.git <clone-path>/command-fix-issue
# Symlink (use full path to cloned repo)
ln -s <clone-path>/command-fix-issue/fix-issue.md ~/.claude/commands/fix-issue.md/fix-issue 456
Where 456 is the GitHub issue number.
- Fetches issue details from GitHub
- Explores codebase to identify root cause
- Creates a fix branch (
fix/456-short-desc) - Writes a failing test that reproduces the bug (Red)
- Implements the minimal fix (Green)
- Runs full test suite and linting
- Creates a PR referencing the issue
This command follows Test-Driven Development:
- Red: Write a test that fails, proving the bug exists
- Green: Write minimal code to make the test pass
- Refactor: Clean up if needed (optional)
ghCLI installed and authenticated- Git repository with GitHub remote
- Claude Code with Opus 4.5 model access
cd <clone-path>/command-fix-issue && git pull