drafael/coding-harness / skills/refactor-code
refactor-code
UnverifiedChange existing code through narrow, behavior-preserving, test-backed simplification without speculative architecture or scope growth. Use for requests to refactor, clean up, restructure, or simplify code. Use explain-code instead when the user only wants an explanation of the current structure.
README.md
View on GitHub# Refactor Code Skill
## Description
Guides safe, incremental refactoring with test-backed changes to improve readability and maintainability without changing external behavior. Use `explain-code` instead when no code change is requested.
## Usage Examples
- "Refactor this class to reduce complexity without changing behavior."
- "Clean up this module and remove duplication safely."
- "Improve this code structure with incremental, test-backed changes."
- "Restructure this component for better separation of concerns."
## Origin (Custom Command Conversion)
This local skill was created by converting a custom slash command from the upstream repository.
- Original command: `.claude/commands/dev/refactor-code.md`
- Upstream repository: [qdhenry/Claude-Command-Suite](https://github.com/qdhenry/Claude-Command-Suite)
## Credits
- Original command author: **Quintin Henry**
- Converted/adapted into local skill format for this repo: `coding-harness`
## License
- Upstream repository README marks license as **MIT**: [qdhenry/Claude-Command-Suite](https://github.com/qdhenry/Claude-Command-Suite)
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the work | Stars: 318k | Updated | Claude CodeCodex | Unverified | Install |
| systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixes | Stars: 318k | Updated | Claude CodeCodex | Unverified | Install |
| test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation code | Stars: 318k | Updated | Claude CodeCodex | Unverified | Install |
| skill-creatoranthropics/skillsCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy. | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |