Skip to content

feat(agent): add pr_solve skill and skill naming enforcement - #142

Merged
gerchowl merged 9 commits into
devfrom
feature/133-pr-solve-skill
Feb 21, 2026
Merged

gerchowl merged 9 commits into
devfrom
feature/133-pr-solve-skill

Conversation

@gerchowl

Copy link
Copy Markdown
Contributor

Description

Add the pr_solve skill — a single entry point that diagnoses all PR failures (CI, review feedback, merge conflicts), presents a structured diagnosis, plans fixes with user approval, and executes them with TDD discipline.

Also introduces a pre-commit hook and BATS test suite to enforce the new underscore-based skill directory naming convention, and expands the TDD scenario checklist with three new categories.

Closes #133

Type of Change

  • feat -- New feature
  • test -- Adding or updating tests
  • docs -- Documentation only

Changes Made

pr_solve skill

  • .cursor/skills/pr_solve/SKILL.md — 6-step workflow: identify PR, gather problems (CI/reviews/merge state), present diagnosis, plan fixes, execute with TDD, verify via ci_check
  • Registered in CLAUDE.md command table
  • Workspace copy synced via sync_manifest.py

Skill naming enforcement

  • scripts/check-skill-names.sh — validates skill directory names match [a-z0-9][a-z0-9_-]*
  • Pre-commit hook check-skill-names in .pre-commit-config.yaml — triggers on changes under .cursor/skills/
  • tests/bats/skill-naming.bats — 12 BATS tests covering valid names, invalid names (colons, dots, uppercase, spaces), multiple violations, empty dirs, real repo validation, and a canary test that injects a bad name into the real .cursor/skills/ to prove the guard catches it

TDD checklist expansion

  • .cursor/rules/tdd.mdc — added canary, idempotency, and concurrency to the test scenario checklist

Changelog Entry

Added

  • pr_solve skill — diagnose PR failures, plan fixes, execute (#133)
    • Single entry point that gathers CI failures, review feedback, and merge state into a consolidated diagnosis
    • Presents diagnosis for approval before any fixes, plans fixes using design_plan conventions, executes with TDD discipline
    • Pre-commit hook check-skill-names enforces [a-z0-9][a-z0-9_-]* naming for skill directories
    • BATS test suite with canary test that injects a bad name into the real repo
    • TDD scenario checklist expanded with canary, idempotency, and concurrency categories

Testing

  • Tests pass locally (just test-bats)
  • All 12 BATS tests pass including canary test
  • Pre-commit hook check-skill-names passes on real repo
  • All pre-commit hooks pass on every commit

Manual Testing Details

  • Ran npx bats tests/bats/skill-naming.bats — 12/12 pass
  • Ran scripts/check-skill-names.sh .cursor/skills — exits 0
  • Verified canary test creates bad:canary dir, checker rejects it, dir is cleaned up

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have updated CHANGELOG.md in the [Unreleased] section (and pasted the entry above)
  • My changes generate no new warnings or errors
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

Refs: #133

@gerchowl gerchowl self-assigned this Feb 21, 2026
@gerchowl
gerchowl merged commit fa2f7d1 into dev Feb 21, 2026
10 checks passed
@gerchowl
gerchowl deleted the feature/133-pr-solve-skill branch February 21, 2026 22:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant