agentsclimarketplace

Ruby refactor

Skill ComeOnOliver/skillshub/skills/pproenca/dot-skills/ruby-refactor

🧠 The right skill, one API call. AI agent skills registry with token-efficient skill resolution. 5,000+ skills from 500+ top repos.

Install
npx -y skills add ComeOnOliver/skillshub --skill ruby-refactor

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

SKILL.md

7.0 KB, as published. Nobody here has run it

Community Ruby Refactoring Best Practices

Comprehensive refactoring guide for Ruby applications, maintained by the community. Contains 45 rules across 8 categories, prioritized by impact to guide automated refactoring and code generation.

When to Apply

Reference these guidelines when:

  • Refactoring Ruby code to reduce complexity and improve design
  • Extracting methods, classes, or value objects from large units
  • Simplifying complex conditionals and deep nesting
  • Reducing coupling between classes and modules
  • Adopting idiomatic Ruby patterns and modern Ruby 3.x features

Rule Categories by Priority

PriorityCategoryImpactPrefix
1Structure & DecompositionCRITICALstruct-
2Conditional SimplificationCRITICALcond-
3Coupling & DependenciesHIGHcouple-
4Ruby IdiomsHIGHidiom-
5Data & Value ObjectsMEDIUM-HIGHdata-
6Design PatternsMEDIUMpattern-
7Modern Ruby 3.xMEDIUMmodern-
8Naming & ReadabilityLOW-MEDIUMname-

Quick Reference

1. Structure & Decomposition (CRITICAL)

2. Conditional Simplification (CRITICAL)

3. Coupling & Dependencies (HIGH)

4. Ruby Idioms (HIGH)

5. Data & Value Objects (MEDIUM-HIGH)

6. Design Patterns (MEDIUM)

7. Modern Ruby 3.x (MEDIUM)

8. Naming & Readability (LOW-MEDIUM)

How to Use

Read individual reference files for detailed explanations and code examples:

Reference Files

FileDescription
references/_sections.mdCategory definitions and ordering
assets/templates/_template.mdTemplate for new rules
metadata.jsonVersion and reference information

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.