Individual skill
clean-code
Use when writing, reviewing, or refactoring code for maintainability and readability. Triggers on code reviews, naming discussions, function design, error handling, and test writing. Based on Robert C. Martin's Clean Code handbook with modern corrections.
skills/.experimental/clean-code/SKILL.md
Source commit cf93c57cac89d6fc3e4194686000411567f5caf3
What was checked
- Matches the observed repository HEAD
- Yes
- Scanner rules are current
- No
- Repository scan complete
- No
- Skill scan complete
- Yes
- Observed behavior
- Not checked yet
- Last checked
- Nov 5, 2026
These are observations at the recorded commit, not a guarantee of safety. Review the source before running it.
Install this skill
Choose an agent in your Stack or copy a command below. Commands fetch the pinned commit and copy only this skill directory. Existing destinations are refused. Copying a command does not install anything.
An install command is unavailable: current rules, complete repository and skill scans, an eligible behavior level and a permitted license are required.
Repository context
- Repository stars (not skill ratings)
- 222
- Repository last updated
- Aug 15, 2026
- License
- MIT
Observed agent integration: No specific integration evidence. Standard SKILL.md installation does not imply verified compatibility.
Files and excerpt
File metadata and permitted, redacted excerpts come from the recorded scan. Source links are pinned to that commit.
Browse files
SKILL.mdcore · 7,040 bytesassets/templates/_template.mddoc · 773 bytesmetadata.jsonasset · 961 bytesreferences/_sections.mddoc · 2,239 bytesreferences/bound-learning-tests.mddoc · 1,933 bytesreferences/bound-wrap-third-party.mddoc · 2,452 bytesreferences/class-cohesion.mddoc · 2,004 bytesreferences/class-isolate-from-change.mddoc · 2,153 bytesreferences/class-organize-for-change.mddoc · 1,937 bytesreferences/class-separate-concerns.mddoc · 2,494 bytesreferences/class-small.mddoc · 2,149 bytesreferences/cmt-avoid-commented-out-code.mddoc · 1,439 bytesreferences/cmt-avoid-redundant.mddoc · 1,445 bytesreferences/cmt-explain-intent.mddoc · 1,648 bytesreferences/cmt-express-in-code.mddoc · 1,880 bytesreferences/cmt-warning-consequences.mddoc · 1,981 bytesreferences/emerge-expressiveness.mddoc · 1,697 bytesreferences/emerge-simple-design.mddoc · 2,211 bytesreferences/err-avoid-null.mddoc · 2,260 bytesreferences/err-define-by-caller-needs.mddoc · 1,834 bytesreferences/err-provide-context.mddoc · 1,669 bytesreferences/err-use-exceptions.mddoc · 3,087 bytesreferences/err-write-try-catch-first.mddoc · 1,809 bytesreferences/fmt-horizontal-alignment.mddoc · 1,785 bytesreferences/fmt-indentation.mddoc · 1,502 bytesreferences/fmt-team-rules.mddoc · 1,587 bytesreferences/fmt-vertical-formatting.mddoc · 2,132 bytesreferences/func-abstraction-level.mddoc · 2,399 bytesreferences/func-command-query-separation.mddoc · 1,563 bytesreferences/func-dry.mddoc · 2,760 bytesreferences/func-minimize-arguments.mddoc · 1,720 bytesreferences/func-no-side-effects.mddoc · 2,414 bytesreferences/func-one-thing.mddoc · 2,587 bytesreferences/func-small.mddoc · 2,951 bytesreferences/name-avoid-disinformation.mddoc · 1,256 bytesreferences/name-avoid-encodings.mddoc · 1,877 bytesreferences/name-class-noun.mddoc · 1,363 bytesreferences/name-intention-revealing.mddoc · 1,576 bytesreferences/name-meaningful-distinctions.mddoc · 1,435 bytesreferences/name-method-verb.mddoc · 1,871 bytesreferences/name-pronounceable.mddoc · 1,158 bytesreferences/name-searchable.mddoc · 1,274 bytesreferences/obj-avoid-hybrids.mddoc · 1,975 bytesreferences/obj-data-abstraction.mddoc · 1,856 bytesreferences/obj-data-object-asymmetry.mddoc · 2,043 bytesreferences/obj-dto.mddoc · 1,907 bytesreferences/obj-law-of-demeter.mddoc · 1,548 bytesreferences/test-build-operate-check.mddoc · 1,858 bytesreferences/test-first-law.mddoc · 1,725 bytesreferences/test-first-principles.mddoc · 2,071 bytesreferences/test-keep-clean.mddoc · 1,773 bytesreferences/test-one-assert.mddoc · 2,310 bytes
Read excerpt
# Robert C. Martin (Uncle Bob) Clean Code Best Practices
Comprehensive software craftsmanship guide based on Robert C. Martin's "Clean Code: A Handbook of Agile Software Craftsmanship", updated with modern corrections where the original 2008 advice has been superseded. Contains 48 rules across 10 categories, prioritized by impact to guide code reviews, refactoring decisions, and new development. Examples are primarily in Java but principles are language-agnostic.
## When to Apply
Reference these guidelines when:
- Writing new functions, classes, or modules
- Naming variables, functions, classes, or files
- Reviewing code for maintainability issues
- Refactoring existing code to improve clarity
- Writing or improving unit tests
- Wrapping third-party dependencies