
from dotfiles-claude10
Practical guide to quantitative code-quality metrics (cyclomatic, cognitive, Halstead, maintainability index) with thresholds, formulas and measurement commands
This skill explains quantitative code-quality metrics and how to measure them across languages. It covers cyclomatic complexity, cognitive complexity, Halstead measures, maintainability index, coupling and cohesion metrics, and practical thresholds for action. The guide includes formulas, example calculations, and commands for tools like ESLint, Radon and SonarQube.
Use when assessing whether a codebase or specific functions meet maintainability and complexity thresholds, during code reviews, automated quality gates, or when planning refactors. It’s useful for developers, reviewers and agents asked to evaluate technical debt or to produce reports on complexity and maintainability.
references/ directory with measurement-tools and threshold guidance (has_references=true)Agents that can run static analysis tooling or suggest refactors (CI automation, code-review bots, Claude Code, Copilot) will benefit most. Agents that can call ESLint, radon or sonar-scanner will be able to produce measured reports.
Reference-style skill providing a comprehensive guide to code quality metrics (cyclomatic complexity, cognitive complexity, Halstead, maintainability index, coupling, cohesion) with thresholds and measurement commands. No scripts to execute — purely informational. Well-structured content with clear tables and examples, though it lacks actionable automation beyond manual commands.
No security concerns — static reference content with no network calls, credentials, or destructive commands. disable-model-invocation flag is set. References to external files that aren't included reduce practical completeness.