{"data":{"slug":"discovered-a71ad684788b072ad33a14a0a25c744004987c0d6e200a27","title":"Pr Prepare","summary":"Analyze unpushed commits and code changes to summarize implementation, review fixes, and readiness to proceed. Optionally align with a related plan document.","url":"https:\/\/skillshunter.net\/skills\/discovered-a71ad684788b072ad33a14a0a25c744004987c0d6e200a27","json_url":"https:\/\/skillshunter.net\/api\/public\/v1\/skills\/discovered-a71ad684788b072ad33a14a0a25c744004987c0d6e200a27","markdown_url":"https:\/\/skillshunter.net\/skills\/discovered-a71ad684788b072ad33a14a0a25c744004987c0d6e200a27.md","download_url":"https:\/\/skillshunter.net\/skills\/discovered-a71ad684788b072ad33a14a0a25c744004987c0d6e200a27\/download","category":{"slug":"software-development","name":"Software & Development"},"editor_note":"Ensure the working directory is the repo root or adjust paths accordingly. Check for unpushed commits and a related plan document in `docs\/plans\/completed\/` before proceeding.","instructions":"---\nname: pr-prepare\ndescription: Analyze commits, and optionally a plan, to summarize what was done, what diverged, and which commits fixed review findings.\nallowed-tools: Bash(git log:*), Bash(git diff:*), Bash(git status:*), Bash(git rev-parse:*), Bash(git branch:*), Bash(ls:*), Read, Glob, Grep\n---\n\n# Preparation Summary\n\nAnalyze commits to produce a summary covering implementation, review fixes, and readiness to proceed. If a related plan exists, include plan alignment analysis.\n\n## Context\n- Repo root: !`git rev-parse --show-toplevel 2>\/dev\/null || pwd`\n- Current branch: !`git rev-parse --abbrev-ref HEAD`\n- Unpushed commits: !`git log @{upstream}..HEAD --oneline 2>\/dev\/null || git log origin\/main..HEAD --oneline`\n- Unpushed commit details: !`git log @{upstream}..HEAD --format=\"%h %s%n%b---\" 2>\/dev\/null || git log origin\/main..HEAD --format=\"%h %s%n%b---\"`\n- Changed files: !`git diff @{upstream}..HEAD --stat 2>\/dev\/null || git diff origin\/main..HEAD --stat`\n- Full diff: !`git diff --no-textconv @{upstream}..HEAD 2>\/dev\/null || git diff --no-textconv origin\/main..HEAD`\n- Working tree status: !`git status --short`\n- Latest plan: !`R=$(git rev-parse --show-toplevel 2>\/dev\/null || pwd) && ls -t \"$R\/docs\/plans\/completed\/\" 2>\/dev\/null | head -1`\n\n## Working directory\n\n`docs\/plans\/completed\/` and any other file paths in this skill are relative to **Repo root** from Context. The cwd may be a subdirectory \u2014 prefix Repo root when calling Read\/Glob\/Grep\/ls. Bare paths are cwd-relative.\n\n## Step 1: Gather artifacts\n\n1. **Plan doc (optional)**: If **Latest plan** is not empty, read it \u2014 but only use it if it relates to the work described in the commits. If the plan is unrelated (different feature, old work), disregard it. Tell the user which plan was found and whether it was used or skipped.\n\n2. **Commits and diff**: Use context data (**Unpushed commit details**, **Changed files**, **Full diff**).\n\n## Step 2: Analyze\n\nIf a related plan was found, analyze:\n- **Plan alignment**: Which plan items were implemented, which were skipped or deferred\n- **Unplanned additions**: Files or behavior not in the original plan\n- **Design divergences**: Where implementation differs from planned approach\n\nBased on the commits and code changes, identify:\n- **What was done**: Concrete changes implemented, grouped by area\n- **Review fixes**: Commits whose message says they address review findings (such as `fix: address code review findings`). Dismissed findings and open concerns are recorded in none of the artifacts this skill reads, so it does not report them.\n\n## Step 3: Output summary\n\n```\n## Preparation Summary\n\n**Plan**: {plan title} (or \"No related plan found\")\n**Commits**: {count} on branch\n**Files changed**: {count}\n\n### What was done\n{Bulleted list of implemented changes, grouped by area}\n\n### Plan alignment (if plan is present)\n{Brief statement: does the implementation match the plan?}\n{List divergences \u2014 what plan said vs what was built, whether intentional}\n{List any unplanned additions}\n{List any missing plan items}\n\n### Review fixes\n{Bulleted list of the review fixes the commits record, or \"None recorded in the commits\"}\n\n### Recommendation\n{Any concerns to address, or \"Ready to proceed with \/reset and \/wrap-up\"}\n```\n\n## Important\n\n- This skill only **analyzes and reports** \u2014 it does NOT modify any files, create commits, or push code\n- If there are no unpushed commits and no uncommitted changes, report that and stop\n- Be concise \u2014 focus on meaningful divergences and actionable findings\n","use_cases":["Summarize unpushed commits for code review","Check alignment between implementation and plan documents","Identify review fixes recorded in commit messages","Generate a readiness report before proceeding with a pull request"],"limitations":[],"compatibility":[],"setup_tip":null,"sample_input":null,"sample_output":null,"source_url":"https:\/\/github.com\/AnotherSava\/claude-code-common\/blob\/1a7f9f9cce53f6946ae1e3a9cc0733f2524a4b93\/claude\/skills\/pr-prepare\/SKILL.md","source_commit":"1a7f9f9cce53f6946ae1e3a9cc0733f2524a4b93","license":null,"version":null,"listing_approved_at":"2026-12-01","created_at":"2026-11-30T08:08:23.000000Z","updated_at":"2026-12-01T12:48:20.000000Z","seo_title":"Pr Prepare - Commit Analysis and Review Summary","seo_description":"Analyze unpushed commits and code changes to summarize implementation, review fixes, and readiness to proceed. Optionally align with a related plan document.","seo_keywords":["commit analysis","code review summary","plan alignment","review fixes","preparation report"]}}