Create minimal, surgical patch plans for targeted fixes. Use when fixing specific issues from review, creating focused patches, or avoiding scope creep in fix implementations.
Creates minimal, surgical patch plans for targeted fixes. Use when fixing specific issues from review, creating focused patches, or avoiding scope creep in fix implementations.
/plugin marketplace add melodic-software/claude-code-plugins/plugin install google-ecosystem@melodic-softwareThis skill is limited to using the following tools:
Create minimal, surgical patch plans for targeted fixes.
"This is a PATCH - keep the scope minimal. Only fix what's described in the issue and nothing more."
Parse the issue clearly:
Do NOT expand scope beyond the reported issue.
Review the relevant code:
# Find relevant files
git diff --stat
grep -r "related_function" src/
# Read the specific code
cat src/component/file.ts
Ask: "What is the smallest change that fixes this?"
| Approach | Lines | Risk |
|---|---|---|
| Surgical fix | 1-10 | Low |
| Targeted fix | 10-50 | Medium |
| Refactor | 50+ | High |
Always prefer surgical fixes for patches.
Document the precise fix:
# Patch: [Concise title]
## Issue Summary
**Problem**: [What's broken]
**Solution**: [Minimal fix]
## Files to Modify
- `path/to/file.ts`: [Specific change]
## Implementation Steps
### Step 1: [Specific action]
[Exact code change]
### Step 2: [Specific action]
[Exact code change]
## Validation
- [Command to verify fix]
- [How to confirm success]
## Patch Scope
- Lines of code: ~X
- Risk level: low
- Testing: [minimal/standard]
Every patch needs verification:
## Validation
1. Run specific test: `npm test path/to/test`
2. Manual verification: [steps]
3. Visual check: [if applicable]
# Patch: [Brief description]
## Metadata
- Issue: [Source of this patch request]
- Severity: [blocker/tech_debt]
## Issue Summary
**Original Spec**: [Link if available]
**Problem**: [Brief description of what's wrong]
**Solution**: [Brief description of the fix]
## Files to Modify
[Only files that need changes - be specific]
- `src/component/Button.tsx`: Fix disabled state
## Implementation Steps
IMPORTANT: Execute every step in order.
### Step 1: [Specific change]
<!-- markdownlint-disable MD033 -->
```jsx
// Before
<button onClick={handleClick}>
// After
<button onClick={handleClick} disabled={isLoading}>
<!-- markdownlint-enable MD033 -->
[Details]
Execute to confirm patch is complete:
npm test src/component/Button.test.tsx# BAD: Expanding scope
While fixing the button, I noticed the form could use
refactoring, so I'll also update the validation logic,
improve the error messages, and add loading states to
all other buttons too.
# BAD: Vague plan
## Implementation
- Fix the button issue
- Make it work correctly
- Test to confirm
# BAD: No verification
## Implementation
1. Change the code
2. Done
Patches typically come from review issues:
/review → Identifies blocker
↓
/patch → Creates surgical fix plan
↓
/implement → Executes patch
↓
/review → Verifies fix (re-review)
Date: 2025-12-26 Model: claude-opus-4-5-20251101
This skill should be used when the user asks to "create a slash command", "add a command", "write a custom command", "define command arguments", "use command frontmatter", "organize commands", "create command with file references", "interactive command", "use AskUserQuestion in command", or needs guidance on slash command structure, YAML frontmatter fields, dynamic arguments, bash execution in commands, user interaction patterns, or command development best practices for Claude Code.
This skill should be used when the user asks to "create an agent", "add an agent", "write a subagent", "agent frontmatter", "when to use description", "agent examples", "agent tools", "agent colors", "autonomous agent", or needs guidance on agent structure, system prompts, triggering conditions, or agent development best practices for Claude Code plugins.
This skill should be used when the user asks to "create a hook", "add a PreToolUse/PostToolUse/Stop hook", "validate tool use", "implement prompt-based hooks", "use ${CLAUDE_PLUGIN_ROOT}", "set up event-driven automation", "block dangerous commands", or mentions hook events (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification). Provides comprehensive guidance for creating and implementing Claude Code plugin hooks with focus on advanced prompt-based hooks API.