/pr-proof:prepare-prooffrom pr-proof
Plans and produces proof (video, screenshots, terminal, API, or none) for a branch's pull request by analyzing the diff, confirming the plan with the user, and orchestrating proof executors.
Ships in pr-proof. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
/pr-proof:prepare-proof [base] [before]
You decide which proof a branch needs, confirm it with the user once, own the app's stack for the whole run, and hand each kind to its executor. Executors never start, seed or stop a stack; you do.
Read ${CLAUDE_SKILL_DIR}/../../references/rules.md first. Its rules bind every step below, and it holds the manifest path, schema, jq write recipe, approval rule and agent-caller block this skill names.
base: the branch the change merges into. Default: the repository's default branch, gh repo view --json defaultBranchRef --jq .defaultBranchRef.name.before: present only when the user asks for "before" screenshots. It passes through to screenshot-proof.Work dir: the manifest's directory, ~/.cache/pr-proof/<repo>/<branch>/, computed as the rules' manifest section shows. Create it with mkdir -p.
Refuse on the default branch or a detached HEAD: the manifest path needs a branch, and there is no change to prove.
Signals. Look up mcp__pr-proof__proof_signals with tool search and call it with base and repo, the absolute path of the branch's working tree (git rev-parse --show-toplevel there): the tool otherwise reads the session's directory, which may be another checkout of the same repository, such as main beside the branch's worktree. When the tool is absent, or its result starts Proof signals unavailable:, judge from the diff alone and note "signals not used" with the reason for the report. A result with coverage.partial true assessed only part of the diff; read the rest yourself.
Backend choice needed: means both a TypeSafe and a Gemini key are set and no backend is configured. Ask the user in one question whether to use TypeSafe, Gemini or both, then call the tool again with backend set to typesafe, gemini or both. Under an agent caller, this question is a Confirmation needed block of its own, before the plan. The report suggests saving the answer as the pr-proof option decision_backend in /config.backend and model name who answered. With comparison, every backend's signals sit there, one entry per backend, or its error; the top-level signals belong to the top-level backend: the primary, unless the primary failed and the other one answered. A kind on which two backends disagree, one suggest and the other reject, counts as uncertain.Judge each kind on its own, as the next section says, then set the signals beside your decisions:
suggest that you do not plan, or whose signal is reject that you do plan, is an overrule: state its reason in one line.uncertain is your call.suggest for terminal that comes only from test changes is an expected overrule: tests never call for a kind by themselves.suppressed true means the backend reads the change as not affecting program behaviour. Planning any kind against it is an overrule too.When no kind applies, the plan is no proof.
Assign files. Give each planned kind the diff's files it proves (git diff --name-only "origin/$base...HEAD", or "$base...HEAD" when origin has no such branch). A file may serve several kinds. The executors confirm and correct them.
Confirm the plan once. Show the whole plan in the user's language and wait for a yes or corrections:
comparison each backend's signal beside it;files;terminal-proof terminal, terminal-proof api, screenshot-proof, walkthrough-video record-only;With before, the same question asks where the base comes from:
base;base, which the plan names: ~/.cache/pr-proof/<repo>/<branch>/base-worktree;Under an agent caller, end your turn with a Confirmation needed block as the rules' agent-caller section says, and continue when the caller resumes you with the answers. Besides step 2's backend choice, this is the only question prepare-proof itself asks before producing proof. The skills it runs keep their own gates, such as walkthrough-video's confirmation of derived requirements and the approval of each video and screenshot.
For no proof, the yes takes you straight to step 8.
Stack. Only when a planned kind needs the running app: screenshots and video always do, api always does, terminal when the command it runs talks to the app. With none of those planned, start nothing.
CLAUDE.md files.Second stack for before, when the user chose it:
origin/<base>, or <base> when origin has no such branch.~/.cache/pr-proof/<repo>/<branch>/base-worktree. Reuse a worktree an earlier run left there only when git worktree list --porcelain registers that path in this repository and git -C <path> rev-parse HEAD prints that commit.git worktree remove --force <path>, leaving alone any stack still running from it (rules: other stacks are off limits). Then git worktree add --detach <path> <commit>.before with no base URL and no second stack, drops only the before shots: do not pass before on, and say so in the report. The after shots go on.Run the executors with the Skill tool, in this order, each only when planned and its stack is up:
pr-proof:terminal-proof terminal, then pr-proof:terminal-proof api;pr-proof:screenshot-proof, with before and the base stack's URL when they survived step 6;pr-proof:walkthrough-video with record-only.Pass each one the app's URLs, where the credentials live (a path or a source, never a value), that kind's files and the run's base. Pass walkthrough-video the branch as the feature and the plan's reason for video as what the viewer should see.
terminal-proof and screenshot-proof write their own manifest entries. A kind that fails, is dropped or is rejected is recorded for the report, and the rest go on; never write an entry for it.
Under an agent caller, an executor's Confirmation needed block goes back to your caller as your own, and you resume the executor's step with the answers.
Write your entries with the rules' jq recipe, $base set to the run's base:
walkthrough-video reports an accepted video: <work dir>/entry.json holds {"kind": "video", "claim": "<one sentence: what the video shows the change doing>", "files": [<the files it reported>], "media": [{"path": "<the MP4's absolute path>"}]}. No accepted video, no entry.entries: [] as the rules show.Report, in the user's language:
files;pr-open must run for the proof to appear in the PR.Then ask before stopping any stack this run started, naming each one. Stopping the base stack also removes its worktree with git worktree remove --force <path>, because the install and env files leave it unclean. Under an agent caller this question goes in a Confirmation needed block. Ask nothing about a stack you reused.
Proof shows a reviewer that the change does what it claims, in a form they can check without running it. Decide each of the four kinds on its own, from the commits, the diffstat and the diff of <base>...HEAD. Tests the change adds or edits are not proof and never call for a kind by themselves.
Choose no proof when the change does not affect program behaviour: documentation and its content, agent instructions and rules, comments, refactors that keep behaviour, dead-code removal, version bumps and changelogs, and local toolchain pins.
A change can need several kinds: a page that also changes the endpoint behind it needs screenshots and api. A visual change that also adds a flow needs screenshots and video. Pick each kind the change itself shows, not kinds a reviewer could gather about unchanged code nearby. When a kind is doubtful, decide from what the diff changes, not from the commit messages' claims.
State each decision with a one-line reason.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
4 skills in this plugin
/screenshot-proofScreenshot the screens a branch changed, at the project's breakpoints, from the URL of an app that is already running, have the user approve each shot, and record the approved shots in the branch's proof manifest for pr-open. Takes "before" shots from a base stack's URL on request. Use when asked for screenshots or screenshot proof of a UI change, whether the user asks directly or prepare-proof or another agent dispatches it./terminal-proofCapture a masked, reviewed transcript of what a change does when run, a CLI command's output in terminal mode or HTTP requests and responses in api mode, and record it as the branch's terminal or API proof for pr-open. Use when asked for terminal or API proof of a change, or when prepare-proof dispatches it. It never starts, seeds or stops a stack./npx claudepluginhub grixu/cc-toolkit --plugin pr-proofOther plugins' skills for the same job