Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

pr-prep

БесплатноБез исполняемых скриптовНе проверен

Prepares pull requests by running quality gates, drafting descriptions, and validating tests. Use when completing a feature and ready for review.

atholaот athola★ 358 звёзд на GitHub16 установок в других каталогах

Об этом скилле

Pull Request Preparation Workflow

When NOT To Use

  • Reviewing someone else's PR (use sanctum:pr-review)
  • Only the commit message is needed (use sanctum:commit-messages)

Usage

Use this skill to stage changes and generate a PR summary. Run Skill(sanctum:git-workspace-review) first to capture the repository state and diffs.

Required Progress Tracking

Create progress items for these steps before starting:

  1. pr-prep:workspace-reviewed
  2. pr-prep:quality-gates
  3. pr-prep:self-reviewed
  4. pr-prep:changes-summarized
  5. pr-prep:testing-documented
  6. pr-prep:pr-drafted
  7. pr-prep:content-verified

Mark each item as complete as the section is finished.

Step 1: Review Workspace (workspace-reviewed)

Confirm that Skill(sanctum:git-workspace-review) is complete. If changes were staged after the initial review, re-execute the skill to refresh the context.

Step 2: Run Quality Gates (quality-gates)

Execute formatting, linting, and tests using project-specific commands (e.g., make lint, make test). Resolve all failures before proceeding. If a task cannot be executed locally, document the reason and the alternative validation performed. Language-specific commands and failure handling are detailed in modules/quality-gates.md.

Capabilities Reference Sync

If any plugin files changed (plugin.json, skills, commands, agents, or hooks), run make docs-sync-check to verify book/src/reference/capabilities-reference.md is current. If it reports discrepancies, run /sync-capabilities --fix or update the reference manually before proceeding.

Step 2.5: Self-Review Pass (self-reviewed)

Read the diff as if you are a reviewer seeing it for the first time. This catches scope creep, stale debug code, and unclear changes before anyone else spends time on them.

Automated checks:

# Check for debug statements left in
git diff --cached --name-only | xargs grep -nE \
  '(console\.log|print\(|debugger|TODO|FIXME|HACK|XXX)' \
  2>/dev/null || true

# Check for commented-out code blocks (3+ consecutive lines)
git diff --cached | grep -c '^+.*//.*[a-zA-Z]' || true

# Check for formatting-only commits mixed with feature work
base="$(git symbolic-ref --short refs/remotes/origin/HEAD)"
git log --oneline "$(git merge-base HEAD "$base")"..HEAD | \
  grep -iE '(fmt|format|lint|style|whitespace)' || true

Machine review:

Run a machine review of the diff before the PR opens. The human reviewer then spends their time on what a machine cannot judge. Use Skill(pensive:unified-review-playbook) for a change that spans several dimensions, or /code-review for a smaller one. Fix or answer each finding before posting.

Then run the three checks reviewers kept finding missed on agent-written changes. They are the author's to run, and a model's review of its own work is not a substitute: in a code-modernization study, models endorsed 31.7% of their own behavior-changing outputs as preserving behavior (arXiv 2605.21537):

  • The change lenses in Skill(pensive:bug-review-playbook) whose triggers the diff matches.
  • Every added or modified test against the merge base, then each behavior-changing hunk reverted alone: Skill(sanctum:validate-pr-playbook) Step 3.
  • A search outside the diff for comments and docs that name what the diff renamed, removed or changed: Skill(sanctum:pr-review-playbook) module review-questions.md, Q4.

Additive bias audit:

Run Skill(imbue:justify-playbook) to compute the additive bias score and check Iron Law compliance. If the score is YELLOW or above, justify each flagged signal before proceeding. If RED or STOP, rethink the approach.

Manual verification:

  • Read the full diff: does every change serve the stated goal?
  • No debug statements or TODO markers left in
  • No commented-out code blocks
  • No formatting changes mixed with logic changes
  • No fixup commits that should be squashed
  • Additive bias score is GREEN or justified YELLOW
  • Each machine-review finding is fixed or answered
  • Iron Law compliance: PASS (no test tampering)

If issues are found, fix them before proceeding.

Step 3: Summarize Changes (changes-summarized)

Start from the analyzer rather than from a fresh reading of the diff:

base="$(git symbolic-ref --short refs/remotes/origin/HEAD)"
python3 "${CLAUDE_PLUGIN_ROOT}/scripts/pr_prep_analyze.py" --base "${base}"

The base is the remote's default branch, because a repository may use master, main or another name. When origin/HEAD is not set, the first command fails. Run git remote set-head origin --auto once, or set base to the branch the PR targets.

It reads the branch's changed files and commits, sorts the files into feature, test, docs and other, flags any ! breaking-change marker in a commit subject, reports the quality gates it can decide from the changed-file list (tests touched, docs touched

Полный SKILL.md на GitHub

Установить pr-prep в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

modules/pr-template.mdmodules/quality-gates.mdmodules/todowrite-patterns.md

FAQ

Что делает скилл pr-prep?

Prepares pull requests by running quality gates, drafting descriptions, and validating tests. Use when completing a feature and ready for review.

Как установить скилл pr-prep?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл pr-prep запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить pr-prep с