clean-code · ciembor — Claude Code skill: rules and installation
This Claude Code skill applies clean-code guidance to readability, naming, and function design. It activates during everyday coding and test-related tasks.
MIT 683 installs ★ 3,328 updated 2026-09-10
npx skills add ciembor/agent-rules-books --skill clean-code -a claude-codeWhat clean-code does
The skill guides changes to readable code, clear names, and small functions with distinct responsibilities. It also covers comments, error handling, and tests.
Before making code or design choices, the agent reads clean-code.mini.md. The longer clean-code.md file is a reference for cases where the short rules do not settle a code-quality tradeoff.
What it helps with
- make existing code easier to read
- choose clearer names for functions and variables
- separate responsibilities across functions
- prepare code for testing
Example prompts for the agent
- Improve this function’s readability and choose clearer names.
- Separate the responsibilities in this code and add suitable tests.
- Review the error handling and comments in this implementation.
How to install clean-code
1Skills CLI (Vercel)
npx skills add ciembor/agent-rules-books --skill clean-code -a claude-code2Manually: put the files in place
~/.claude/skills/clean-code/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/clean-code/
1Skills CLI (Vercel)
npx skills add ciembor/agent-rules-books --skill clean-code -a codex2Manually: put the files in place
.agents/skills/clean-code/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add ciembor/agent-rules-books --skill clean-code -a cursor2Manually: put the files in place
.cursor/skills/clean-code/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install ciembor/agent-rules-books clean-code2Manually: put the files in place
.github/skills/clean-code/SKILL.md1Skills CLI (Vercel)
npx skills add ciembor/agent-rules-books --skill clean-code -a gemini-cli2Platform CLI
gemini skills install https://github.com/ciembor/agent-rules-books --path clean-codeManually: put the files in place
.devin/skills/clean-code/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add ciembor/agent-rules-books --skill clean-code -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about clean-code
How do I install clean-code in Claude Code?
Run npx skills add ciembor/agent-rules-books --skill clean-code -a claude-code. The skill file is located at ~/.claude/skills/clean-code/SKILL.md.
What does clean-code do?
It guides the agent on readability, naming, function design, comments, errors, and tests. The agent starts with clean-code.mini.md and consults clean-code.md when the short rules do not cover the current tradeoff.
When does clean-code use its longer reference?
The agent consults clean-code.md when the guidance in clean-code.mini.md is not enough to decide a code-quality question.
Source text
SKILL.md · MIT
--- name: clean-code description: Apply Robert C. Martin-inspired clean code rules when improving readability, naming, function design, responsibilities, or testable everyday code. license: MIT --- # Clean Code Skill Use this skill when a task involves everyday implementation quality, naming, small functions, readable control flow, responsibilities, comments, errors, or tests. Before making design or code decisions, read and apply [clean-code.mini.md](clean-code.mini.md). Use [clean-code.md](clean-code.md) only as a deeper reference when the mini rules are not enough for the current code-quality tradeoff.
© ciembor · MIT · ciembor/agent-rules-books
Similar skills
All skills for Code review and refactoring →clean-code by other authors comes first.