br4zz4:skill:design

Enforces SOLID, DRY, KISS, and Clean Code principles when writing or reviewing code.

Updated May 25, 2025
One-click install
npx skills add https://github.com/oporpino/commons --skill br4zz4-skill-design-oporpino
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: br4zz4:skill:design
Source: https://github.com/oporpino/commons/tree/main/ai/shared/skills/br4zz4%3Adesign
Command: npx skills add https://github.com/oporpino/commons --skill br4zz4-skill-design-oporpino

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Codebases accumulate duplication, over-engineered abstractions, and unreadable functions over time. This Skill applies senior-engineer judgment to every piece of code written or reviewed, keeping it simple, maintainable, and free of repetition. ## Core Features & Use Cases - Principle Enforcement: Applies SOLID, DRY, KISS, and Clean Code rules to all code generation and review tasks. - Code Smell Detection: Identifies and fixes common smells such as deep nesting, mixed I/O and logic, copy-pasted logic, and unnecessary abstractions. - Refactoring Guidance: Provides concrete before/after patterns showing how to restructure vague, bloated functions into single-responsibility units. - Use Case: When asking an AI to implement a new feature or review a pull request, this Skill ensures the output favors fewer lines, precise naming, and self-explanatory code over clever or verbose solutions. ## Quick Start Review this function and refactor it to follow SOLID, DRY, and KISS principles with clear naming and no duplication.

Frequently Asked Questions about br4zz4:skill:design

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I apply SOLID principles when writing code?▼

Apply SOLID by giving each function or module one responsibility, extending behavior without modifying existing code, honoring type contracts, keeping interfaces small, and depending on abstractions rather than concrete implementations.

How to refactor duplicated code following DRY principle?▼

Extract any logic written more than once into a single shared function so each piece of logic exists in exactly one place. Duplication is a maintenance liability, so copy-pasted blocks should always be consolidated.

What code smells indicate poor function design?▼

Common smells include functions with 3+ levels of nesting, functions mixing I/O with logic, large match or switch blocks with repeated branches, and comments explaining what the code does instead of self-explanatory code.

When should I avoid creating abstractions in code?▼

Avoid abstractions used only once; inline them instead. Abstractions must earn their place, so only abstract when you have two or more concrete cases, and prefer the simplest solution that works.

Does this code review approach work for any programming language?▼

Yes, the principles are language-agnostic since SOLID, DRY, KISS, and Clean Code apply universally. The included example uses Rust, but the same rules about naming, single responsibility, and simplicity transfer to any language.