commit
Create git commits with user approval and no Claude attribution
Check for violations of the Single Way to Do Things principle (MOST IMPORTANT)
$ npx -y skills add dcouple/Pane --agent claude-codeHow it fires
How this command gets triggered: by you, by Claude, or both.
/single-patternContext preview
What this command does when you run it.
Check for violations of the Single Way to Do Things principle (MOST IMPORTANT)
allowed-tools: Bash(git diff:*), Bash(git log:*), Bash(git show:*), Bash(git rev-parse:*), Bash(git branch:*), Read, Grep, Glob, TodoWrite description: Check for violations of the Single Way to Do Things principle (MOST IMPORTANT)
You are reviewing code changes for violations of the **Single Way to Do Things** principle.
**THIS IS THE MOST IMPORTANT PRINCIPLE.**
There should be only ONE implementation pattern per feature/behavior in the codebase.
**Why this is critical:**
**This is critical for scaling the codebase and reducing proliferation of similar code.**
# Get current branch git rev-parse --abbrev-ref HEAD # Get changed files git diff main...HEAD --name-only # Get full diff git diff main...HEAD
Use TodoWrite to track each new pattern to investigate.
For each changed file, identify:
Search the diff for:
For each new hook found: 1. Note its purpose/functionality 2. Search codebase for existing hooks with similar purpose 3. Flag if multiple hooks now do similar things
Search for:
For each new component: 1. Note what it renders/does 2. Search for existing similar components 3. Flag if this could have extended an existing component
Search for:
For each: 1. Note the functionality 2. Search `libs/shared/` for existing utilities 3. Search local utils for similar functions 4. Flag duplication
For backend changes, check:
Compare to existing patterns in the same module.
Check for:
For EACH new pattern identified:
1. Grep for similar function/component names 2. Grep for similar functionality (key terms) 3. Read similar files to understand existing patterns 4. Check libs/shared/ for shared implementations
For each new pattern, answer:
# Single Way to Do Things Report
**Branch:** {branch}
**Status:** {PASS | WARN | FAIL}
**Risk Level:** {LOW | MEDIUM | HIGH | CRITICAL}
## Summary
{Assessment of pattern proliferation risk}
## New Patterns Introduced
### Pattern 1: {name}
**Type:** {hook | component | utility | API | state}
**Location:** {file:line}
**Purpose:** {what it does}
**Existing Alternatives Found:**
| Alternative | Location | Similarity |
|-------------|----------|------------|
| {name} | {path} | {how similar} |
**Assessment:** {Should this use existing pattern? Should patterns be unified?}
### Pattern 2: {name}
{Same structure}
## Pattern Proliferation Risks
### Critical (Multiple Ways Now Exist)
| Feature/Behavior | Implementations | Risk |
|------------------|-----------------|------|
| {what it does} | {list of implementations} | {assessment} |
**Impact:** Future development will likely create MORE implementations.
### Warnings (Potential Duplication)
| New Pattern | Similar To | Recommendation |
|-------------|------------|----------------|
| {new} | {existing} | {unify/keep separate/other} |
## Existing Patterns That Should Have Been Used
1. **{pattern name}** at `{path}`
- Already handles: {functionality}
- New code should: {how to use it instead}
## Recommended Actions
### Must Do (Before Merge)
1. {action} - {reason}
### Should Do (Technical Debt if Skipped)
1. {action} - {reason}
### Consider (Pattern Unification)
1. {action} - {reason}
## Pattern Inventory
After this PR, here are the ways to do {common thing}:
| Implementation | Location | Notes |
|----------------|----------|-------|
| {impl 1} | {path} | {original/new/should deprecate} |
| {impl 2} | {path} | {original/new/should deprecate} |
**Recommendation:** {Which should be the canonical pattern?}1. Save report to `tmp/review-single-pattern-{branch}.md` 2. Present summary:
Every duplicate pattern: 1. Confuses future developers (human and AI) 2. Increases maintenance burden 3. Leads to inconsistent behavior 4. Makes refactoring harder 5. Causes LLMs to create even MORE patterns
**One way to do things = scalable, maintainable codebase.**
Run this analysis now on the current branch.
Repo: dcouple/Pane
Create git commits with user approval and no Claude attribution
You are tasked with creating detailed implementation plans through an interactive, iterative process. You should be skeptical, thorough, and work…
Generate comprehensive PR descriptions following repository templates
You are tasked with implementing an approved technical plan from `thoughts/shared/plans/`. These plans contain phases with specific changes and success…
Iterate on existing implementation plans with thorough research and updates
You are tasked with conducting comprehensive research across the codebase to answer user questions. You will spawn one or more parallel sub-agents to perform…