Skip to content
Development
Skill

/dry

DRY (Don't Repeat Yourself) review rules for code reviews: find the same knowledge — a rule, a constant, a parser, a validation, a protocol detail — implemented in several places that must change together, and tell it apart from code that merely looks alike. Use when reviewing a

From plugin
claude-plugins
1614 skills1 agent1 command

Claude Code

$ npx -y skills add siva01c/claude-plugins --skill dry --agent claude-code

SKILL.md

dry.SKILL.md
name: dry
description: >
  DRY (Don't Repeat Yourself) review rules for code reviews: find the same knowledge — a rule, a
  constant, a parser, a validation, a protocol detail — implemented in several places that must
  change together, and tell it apart from code that merely looks alike. Use when reviewing a
  diff, a pull request or recent changes for duplication, on "DRY review", "is this
  duplicated", "copy-paste check", or when a review checklist asks for DRY. Pair it with the
  solid skill for design and with owasp-asvs for security.

DRY Review

DRY is about **knowledge, not text**. A finding is the same decision encoded in two or more places that have to change together — so that changing one and forgetting the other is a bug waiting to happen. Two blocks of similar-looking code that encode *different* decisions are not duplication, and merging them would couple things that should vary independently.

What to look for

  • **Rules and validation** — the same allow-list, regex, limit or permission check in a form,

an API endpoint and a CLI command.

  • **Constants and magic values** — a status name, a timeout, a URL, a field name or a path

spelled out in several files instead of defined once.

  • **Parsers and formats** — two hand-written parsers or serializers for the same file, header,

JSON shape or command output.

  • **Protocol details** — the same auth header, retry policy, pagination loop or error mapping

re-implemented per client.

  • **Copied functions** — a helper copied into a second module with small edits, where both

copies are still meant to behave the same.

  • **Docs and code** — a procedure described in two documents, or a value documented in a README

and hard-coded elsewhere, when both must stay in sync.

In a diff, check first whether the change **adds** a copy of something that already exists in the codebase: search for the key identifiers, strings and regexes it introduces.

Not a finding

  • Similar code that encodes different decisions, or would diverge on the next change.
  • Two or three lines of glue, test setup or boilerplate the framework expects.
  • Tests that restate expected values on purpose.
  • Duplication across separately released projects (a public library and a private monorepo)

that are deliberately kept standalone.

  • Generated, vendored and lock files.

Severity

  • `high` — the copies have **already drifted**: they disagree today, and you can show the input

that behaves differently in each.

  • `medium` — default: the copies are identical now but must change together, and nothing ties

them.

  • `low` — small repeated literals or helpers where a mismatch would be cosmetic.

Reporting a finding

Each finding carries:

  • **rule** — `DRY`;
  • **locations** — `file:line` of **every** copy, not just the one in the diff;
  • **knowledge** — one sentence naming the single decision the copies share;
  • **cost** — what goes wrong when one copy changes and the other does not (or already has);
  • **fix direction** — where the one source of truth should live, preferring an existing module,

config or constant over a new abstraction.

Verify each finding by reading all copies side by side before keeping it. Fewer, true findings beat a long list.

Read more
@siva01c
Ships withclaude-plugins

A curated collection of Claude Code plugins for Drupal development, security, and deployment. Each plugin covers one topic — Drupal itself, DDEV, Docker, CI/CD, git workflows, and security verification — so you install only what you need.

1614 skills1 agent
Get the whole plugin

Stars on GitHub

Momentum

stars in total
16
Star history of siva01c/claude-plugins on GitHub, a chart by star-history.com

Other skills on claude-plugins.

github-actions

github-actions

Use this skill when authoring or debugging GitHub Actions workflows (.github/workflows/*.yml) — e.g. "add CI for this Drupal…

gitlab-ci

gitlab-ci

Use this skill when authoring or debugging GitLab CI/CD pipelines (.gitlab-ci.yml) — e.g. "add a CI pipeline for this Drupal…

docker-compose

docker-compose

Use this skill when authoring or editing Docker Compose files (compose.yaml / docker-compose.yml), running multi-container…

docker-model

docker-model

Use this skill when running local AI models with Docker Model Runner — the `docker model` CLI — e.g. "run an LLM locally with…

More skills from other plugins.

brainstorming
Auto-invoked

brainstorming

You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…

@obra@obraInstall Skill
ask-matt

ask-matt

Ask which skill or flow fits your situation. A router over the skills in this repo.

skills2w309k
@mattpocock@mattpocockInstall Skill
accessibility
Auto-invoked

accessibility

Design, implement, and audit accessible UI to WCAG 2.2 Level AA across Web, iOS, and Android — semantic ARIA roles and labels,…

ecc2w293k
@affaan-m@affaan-mInstall Skill
compiler-commit

compiler-commit

Use when you want to verify compiler changes and commit with the correct convention. Runs tests, lint, and format, then commits…

react5d252k
@facebook@facebookInstall Skill

Questions about dry.

Which coding agents can use dry?
dry installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.