cm-clean-code

Detect code smells via the 7-Point Hygiene Checklist and refactor with tests.

48|23|Updated Mar 17, 2026
One-click install
npx skills add https://github.com/tody-agent/codymaster --skill cm-clean-code
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cm-clean-code
Source: https://github.com/tody-agent/codymaster/tree/main/skills/cm-clean-code
Command: npx skills add https://github.com/tody-agent/codymaster --skill cm-clean-code

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Codebases accumulate dead code, duplicates, naming mess, and general code smells, making maintenance painful and risky.

Core Features & Use Cases

  • 7-Point Hygiene Checklist: automatic detection of dead code, unused imports, long functions, naming issues, duplicate logic, and nesting depth.
  • SCAN → CLEAN → VERIFY workflow: detect smells, apply safe refactors, verify tests and CI readiness.
  • Integration-ready: works with cm-tdd, cm-reactor, and cm-code-review to maintain code health across sprints.

Quick Start

Run a hygiene pass on the latest changes to identify and clean code smells.

Frequently Asked Questions about cm-clean-code

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I identify code smells and dead code in my codebase?

Code smells like dead code, unused imports, and duplicate logic are identified using a 7-Point Hygiene Checklist that automatically detects naming issues, long functions, and deep nesting across languages.

What is the best way to refactor messy code safely during a debt sprint?

The best way to refactor messy code safely is a SCAN, CLEAN, and VERIFY workflow that detects smells, applies TRIZ-inspired refactors, and validates changes with tests for CI readiness.

Can I use this clean code approach for post-migration cleanup across different repos?

Yes, this clean code approach applies during post-migration cleanup across languages and repos, automatically detecting hygiene issues and performing safe refactors to improve maintainability.

Does static analysis work with test-driven development and code review workflows?

Static analysis integrates directly with test-driven development and code review workflows, maintaining code health across sprints by detecting smells and verifying refactored changes.

When should I perform a code hygiene pass on my latest changes?

You should perform a code hygiene pass during feature completion, debt sprints, and post-migration cleanup to identify and remediate code smells before they accumulate.

What types of code smells are detected by the 7-Point Hygiene Checklist?

The 7-Point Hygiene Checklist detects dead code, unused imports, long functions, naming issues, duplicate logic, and nesting depth to improve overall maintainability.