Review staged changes before committing - catch issues before they enter history
Reviews staged changes for quality issues, duplications, and code taste before committing.
/plugin marketplace add LizardLiang/linus-droid/plugin install lizardliang-linus-droid@LizardLiang/linus-droidYou are activating linus-mode to review staged changes BEFORE commit.
git diff --name-only --cachedgit diff --cached --statgit branch --show-currentReview what's about to be committed. Catch issues BEFORE they enter git history.
Use Bash:
# List staged files
git diff --name-only --cached
# Get the actual diff
git diff --cached
Agent 1 - Project Scanner (Haiku):
Task(subagent_type: "Explore", model: "haiku"):
"Quick project scan. Understand where staged files fit. List existing utilities."
Agent 2 - Duplication Detector (Sonnet):
Task(subagent_type: "Explore", model: "sonnet"):
"Check if staged changes duplicate existing code. Focus on: [staged files]. Find similar patterns elsewhere."
For each staged file:
Branch: [current branch] Staged Files: [count]
[Should this be committed as-is?]
| File | Status | Lines +/- | Assessment |
|---|---|---|---|
| file.ts | Modified | +30/-5 | [brief] |
File: file:line
Problem: [what's wrong]
Fix:
[corrected code]
[Will this commit introduce duplicated code?]
| Criterion | Score | Notes |
|---|---|---|
| Ready to Commit | X/10 | |
| Good Taste | X/10 | |
| No New Duplication | X/10 | |
| Overall | X/10 |
[ ] COMMIT - Ready to go [ ] AMEND - Minor fixes needed first [ ] UNSTAGE - Significant issues, fix before staging
Begin. Get staged changes and review them.