skills/mp-code-clean/SKILL.md
Review and fix code quality issues immediately: deduplicate, remove repetition, remove dead code. Use when: "clean code", "deduplicate this module", "remove dead code"
npx skillsauth add MartinoPolo/mpx-claude-code mp-code-cleanInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Run focused code-quality cleanup and apply easy wins immediately. Target duplication, repetition, and dead/unused code. $ARGUMENTS
Parse $ARGUMENTS as file/s or folder/s scope, then build meaningful module groups.
Rules:
For each file group, spawn a review sub-agent.
Use this exact review prompt shape:
You are reviewing one module group for immediate code cleanup.
Goal:
- Find DRY violations, duplication/repetition, and dead/unused code.
- Propose low-risk cleanups that preserve behavior.
- Code line number reduction is the best win here.
Input:
- Module group: <folder/files list>
- Boundaries: review only this group and direct dependencies.
Required actions:
1) Identify duplicated logic and repeated patterns.
2) Identify dead/unused exports, imports, helpers, and unreachable code.
3) Prioritize easy wins first.
4) Produce an edit plan with exact files and concrete changes.
Required output:
- Findings grouped by file
- Ranked cleanup plan (easy wins first)
- Risk notes per proposed change
For each reviewed group, spawn a fix sub-agent with approved findings.
Use this exact fix prompt shape:
You are applying approved cleanup changes for one module group.
Goal:
- Execute the approved deduplication and dead-code-removal plan.
- Keep behavior and signatures stable.
Input:
- Module group: <folder/files list>
- Approved findings/plan: <review output>
Required actions:
1) Apply deduplication and repetition removal.
2) Remove dead/unused code safely.
3) Keep public contracts stable unless plan explicitly allows change.
4) Avoid broad rewrites and feature changes.
5) Run targeted checks/tests for touched files when available.
Required output:
- Applied edits by file
- What was removed/consolidated
- Validation results
- Follow-ups not completed and why
Fix subagent must reject unapproved scope expansion.
Run targeted validation on touched groups. Report outcomes per group.
Display:
tools
Show current project progress. Displays phase status and next steps. Use when: "show status", "project progress", "what's done"
data-ai
Unified project setup. Auto-detects state and orchestrates mpx skills/agents for init, conversion, or restructure.
testing
Track bugs/issues in .mpx/ phase system. Parses reports, finds related phases, adds fix tasks or creates bugfix phases. Use when: "track this bug", "add issue to project", "log this bug", "add bug to checklist"
development
Project workflow guidance for spec-driven development. Background knowledge auto-loaded when relevant.