Agent skill · Testing & QA

regex-builder

Build a regular expression from a plain-English description, or explain an existing one. Use when asked to write a regex, match/validate/extract a pattern, or understand what a regex does. Produces the regex, a token-by-token breakdown, passing and failing test cases, and notes on flavor/edge cases.

mohitagw15856github.com/mohitagw15856GitHub ↗
claude-codecursorMIT
Install
npx skills add mohitagw15856/pm-claude-skills --skill regex-builder --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 1
SKILL.md size: 3 KB
Bundled scripts: none
Path: skills/regex-builder/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 1,255
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Regex Builder & Explainer Skill Produce correct, readable regular expressions — and explain them so the user actually understands what they're shipping. ## Working from a brief Infer the regex flavor (JavaScript/PCRE/Python/Go) from context; if unstated, default to one and say so *(assumed — confirm)*. Always deliver a working pattern and tests even from a loose description. Never leave placeholders. ## Required Inputs - **What should match and what should NOT** — 3+ positive examples and, critically, 2+ near-miss negatives (the strings that *look* matchable but must be rejected). The negatives are where every regex bug lives. - **The engine/flavor** (JavaScript, PCRE, Python `re`, RE2, grep -E…) — anchors, lookbehind, and Unicode behaviour differ enough to break portability silently. - **Where it runs** — validation, extraction, or replacement changes how greedy the pattern should be. ## Two modes - **Build:** the user describes what to match → produce the regex. - **Explain:** the user pastes a regex → break it down. Detect which from the input. ## Output Structure ### Pattern The regex in a code block, plus the **flavor** and any **flags** (e.g. `i`, `g`, `m`) and why. ### Bre

What's inside
Steps it walks through
  1. Working from a brief
  2. Required Inputs
  3. Two modes
  4. Output Structure
  5. Pattern
  6. Breakdown
  7. Test cases
  8. Notes
  9. Quality Checks
  10. Anti-Patterns
More from pm-claude-skills
All skills →
About this skill
What does the regex-builder skill do?

Build a regular expression from a plain-English description, or explain an existing one. Use when asked to write a regex, match/validate/extract a pattern, or understand what a regex does. Produces the regex, a token-by-token breakdown, passing and failing test cases, and notes on flavor/edge cases.

How do I install it?

Run `npx skills add mohitagw15856/pm-claude-skills --skill regex-builder --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From mohitagw15856/pm-claude-skills, a repository with 1,255 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going