dry-refactor

Community

Eliminate code duplication, enhance maintainability.

AuthorPaulRBerg
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This skill guides developers in identifying and eliminating code duplication (DRY - Don't Repeat Yourself), leading to cleaner, more maintainable, and less error-prone software.

Core Features & Use Cases

  • Duplication Detection: Helps identify code smells like numbered variables, parallel function names, and near-identical logic.
  • Refactoring Techniques: Provides a catalog of techniques such as Extract Function, Parameterize, Polymorphism, and Strategy Pattern.
  • Strategic Guidance: Advises on when to refactor (Rule of Three) and, crucially, when not to abstract (coincidental similarity, premature abstraction).
  • Use Case: When you notice similar blocks of code appearing multiple times in your project, use this skill to systematically apply refactoring techniques to consolidate logic and improve code structure.

Quick Start

To refactor duplicate logic, identify the repeated code, analyze its coupling, then apply a technique like 'Extract Function' to create a reusable abstraction.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: dry-refactor
Download link: https://github.com/PaulRBerg/dot-claude/archive/main.zip#dry-refactor

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.