Skip to content

Coding guide that applies Robert C. Martin's Clean Code rules to naming, functions, classes, errors, and tests.

CCM score
53 of 100
skills.sh installs
361
GitHub stars
60
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers naming, functions, comments, objects and data structures, error handling, unit tests, and classes, with quick-reference tables for each
  • Includes 7 chapter files (names.md, functions.md, classes.md, and others) plus a reference of 66 code smells in smells-and-heuristics.md
  • Enforces rules such as no null returns, no flag arguments, at most three function arguments, and one reason to change per class
  • Designed for reviewing, writing, or refactoring code that has become complex or hard to read

Install

$ npx -y skills add ratacat/claude-skills --skill clean-code -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

Clean Code

Overview

Clean code reads like well-written prose. Every name reveals intent. Every function tells a story. Every class has a single purpose. The goal isn't just working code—it's code that others can understand quickly, modify safely, and extend confidently.

"Clean code always looks like it was written by someone who cares." — Michael Feathers

"You know you are working on clean code when each routine turns out to be pretty much what you expected." — Ward Cunningham

The Boy Scout Rule: Leave the code cleaner than you found it. Every commit should improve quality, even if just slightly. Small improvements compound.

Chapter References

This skill provides an overview with quick references. For detailed guidance with examples, see the chapter files:

Details

Repository
github.com/ratacat/claude-skills
Categories
Code Review & Quality, Technical Documentation
First seen
Jun 3, 2026

Questions

What does the clean-code skill do for Claude Code?

The clean-code skill applies Robert C. Martin's Clean Code principles when Claude writes, reviews, or refactors code. It covers naming variables and functions, structuring classes, handling errors, and writing tests, and it helps when code feels complex or hard to understand.

How do I install the clean-code skill?

Run npx -y skills add ratacat/claude-skills --skill clean-code -y in your project to install it. After installation, Claude applies its guidance on naming, functions, classes, error handling and tests when it works on code.

Which skills lead clean-code in the Code Review & Quality category?

In the Code Review & Quality category, clean-code sits alongside improve-codebase-architecture, codebase-design, code-review, setup-ts-deep-modules and caveman-review. Its focus is on readability and maintainability at the level of names, functions, classes and tests.

Does clean-code need any accounts, keys or extra tools?

The listing and SKILL.md give no accounts, API keys or extra tools for clean-code. It is a knowledge skill that Claude applies to code it writes or reviews.

More from ratacat/claude-skills

All 3

Similar to Clean Code

More Code Review & Quality