From oh-my-claudeagent
MUST USE for ANY git operations. Atomic commits, rebase/squash, history search (blame, bisect, log -S). Triggers: 'commit', 'rebase', 'squash', 'who wrote', 'when was X added', 'find the commit that'.
npx claudepluginhub utsavbalar1231/oh-my-claudeagent --plugin oh-my-claudeagentThis skill uses the workspace's default tool permissions.
All changes via git in Bash. No Write/Edit (direct file modification) or Agent (delegation).
Generates design tokens/docs from CSS/Tailwind/styled-components codebases, audits visual consistency across 10 dimensions, detects AI slop in UI.
Records polished WebM UI demo videos of web apps using Playwright with cursor overlay, natural pacing, and three-phase scripting. Activates for demo, walkthrough, screen recording, or tutorial requests.
Delivers idiomatic Kotlin patterns for null safety, immutability, sealed classes, coroutines, Flows, extensions, DSL builders, and Gradle DSL. Use when writing, reviewing, refactoring, or designing Kotlin code.
All changes via git in Bash. No Write/Edit (direct file modification) or Agent (delegation).
MCP tools: evidence_log (verification), ast_search (code archaeology).
Three specializations: Commit Architect (atomic commits, style detection), Rebase Surgeon (history rewriting, conflicts), History Archaeologist (when/where changes introduced).
Claude Code cannot interact with spawned processes. ALL git commands must be prefixed:
GIT_EDITOR=: EDITOR=: GIT_SEQUENCE_EDITOR=: GIT_PAGER=cat GIT_TERMINAL_PROMPT=0 git <command>
Prevents editor hangs without user configuration.
| User Request Pattern | Mode | Jump To |
|---|---|---|
| "commit", changes to commit | COMMIT | Phase 0-5 |
| "rebase", "squash", "cleanup history" | REBASE | Phase R1-R4 |
| "find when", "who changed", "git blame", "bisect" | HISTORY_SEARCH | Phase H1-H3 |
CRITICAL: Don't default to COMMIT mode. Parse the actual request.
ONE COMMIT = FAILURE. Default: CREATE MULTIPLE COMMITS. Single commit = bug in your logic.
HARD RULE:
3+ files changed -> MUST be 2+ commits (NO EXCEPTIONS)
5+ files changed -> MUST be 3+ commits (NO EXCEPTIONS)
10+ files changed -> MUST be 5+ commits (NO EXCEPTIONS)
About to make 1 commit from multiple files → WRONG. STOP AND SPLIT.
SPLIT BY:
| Criterion | Action |
|---|---|
| Different directories/modules | SPLIT |
| Different component types (model/service/view) | SPLIT |
| Can be reverted independently | SPLIT |
| Different concerns (UI/logic/config/test) | SPLIT |
| New file vs modification | SPLIT |
ONLY COMBINE when ALL of these are true:
MANDATORY SELF-CHECK before committing:
"I am making N commits from M files."
IF N == 1 AND M > 2:
-> WRONG. Go back and split.
-> Write WHY each file must be together.
-> If you can't justify, SPLIT.
Execute ALL in parallel:
# Group 1: Current state
git status
git diff --staged --stat
git diff --stat
# Group 2: History context
git log -30 --oneline
git log -30 --pretty=format:"%s"
# Group 3: Branch context
git branch --show-current
git merge-base HEAD main 2>/dev/null || git merge-base HEAD master 2>/dev/null
git rev-parse --abbrev-ref @{upstream} 2>/dev/null || echo "NO_UPSTREAM"
git log --oneline $(git merge-base HEAD main 2>/dev/null || git merge-base HEAD master 2>/dev/null)..HEAD 2>/dev/null
Count from git log -30:
- Korean characters: N commits
- English only: M commits
DECISION:
- If Korean >= 50% -> KOREAN
- If English >= 50% -> ENGLISH
| Style | Pattern | Example |
|---|---|---|
SEMANTIC | type: message or type(scope): message | feat: add login |
PLAIN | Just description, no prefix | Add login feature |
SHORT | Minimal keywords | format, lint |
SENTENCE | Full sentence style | Implemented the new login flow |
MANDATORY OUTPUT:
STYLE DETECTION RESULT
======================
Language: [KOREAN | ENGLISH]
Style: [SEMANTIC | PLAIN | SHORT]
Reference examples from repo:
1. "actual commit message from log"
2. "actual commit message from log"
BRANCH_STATE:
current_branch: <name>
has_upstream: true | false (from NO_UPSTREAM check in Phase 0)
commits_ahead: N
REWRITE_SAFETY:
- On main/master: NEVER rewrite
- has_upstream=false: AGGRESSIVE_REWRITE allowed
- has_upstream=true, commits pushed: CAREFUL_REWRITE (warn on force push)
FORMULA: min_commits = ceil(file_count / 3)
3 files -> min 1 commit
5 files -> min 2 commits
9 files -> min 3 commits
15 files -> min 5 commits
RULE: Different directories = Different commits (almost always)
RULE: Test files MUST be in same commit as implementation
Test patterns to match:
- test_*.py <-> *.py
- *_test.py <-> *.py
- *.test.ts <-> *.ts
- *.spec.ts <-> *.ts
COMMIT PLAN
===========
Files changed: N
Minimum commits required: ceil(N/3) = M
Planned commits: K
Status: K >= M (PASS) | K < M (FAIL - must split more)
COMMIT 1: [message in detected style]
- path/to/file1.py
- path/to/file1_test.py
Justification: implementation + its test
For each planned commit with 3+ files, write ONE sentence why they MUST be together. If you cannot write it, SPLIT.
Valid: "implementation file + its direct test", "migration + model that would break without both" Invalid: "all related to feature X", "they were changed together"
Use TaskCreate to register each commit as a trackable item. Mark each in_progress before executing, completed after.
For each new commit group, in dependency order:
# Stage files
git add <file1> <file2> ...
# Verify staging
git diff --staged --stat
# Commit with detected style
git commit -m "<message-matching-detected-style>"
# Verify
git log -1 --oneline
# Check working directory clean
git status
# Review new history
git log --oneline $(git merge-base HEAD main 2>/dev/null || git merge-base HEAD master)..HEAD
| If git log shows... | Use this style |
|---|---|
feat: xxx, fix: yyy | SEMANTIC |
Add xxx, Fix yyy | PLAIN |
| Full sentences | SENTENCE |
format, lint | SHORT |
| Mix of above | Use MAJORITY |
| Condition | Risk Level | Action |
|---|---|---|
| On main/master | CRITICAL | ABORT - never rebase main |
| Dirty working directory | WARNING | Stash first |
| Pushed commits exist | WARNING | Will require force-push; confirm |
| All commits local | SAFE | Proceed freely |
# Find merge-base
MERGE_BASE=$(git merge-base HEAD main 2>/dev/null || git merge-base HEAD master)
# For SQUASH (combine all into one):
git reset --soft $MERGE_BASE
git commit -m "Combined: <summarize all changes>"
# For AUTOSQUASH:
GIT_SEQUENCE_EDITOR=: git rebase -i --autosquash $MERGE_BASE
| Goal | Command |
|---|---|
| When was "X" added? | git log -S "X" --oneline |
| When was "X" removed? | git log -S "X" --all --oneline |
| What commits touched "X"? | git log -G "X" --oneline |
| Who wrote line N? | git blame -L N,N file.py |
| When did bug start? | git bisect start && git bisect bad && git bisect good <tag> |
| File history | git log --follow -- path/file.py |