write-pr

Solid

Draft a pull request title and body from the current branch's diff and commit history, following the project's PR template and title conventions. Use when the user is about to open a PR and wants ready-to-paste content, or asks to write, draft, or fill in a PR description. Read-only — never opens or pushes the PR.

Code & Development 17 stars 1 forks Updated 2 weeks ago MIT

Install

View on GitHub

Quality Score: 82/100

Stars 20%
42
Recency 20%
90
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# Write PR Turn the current branch's changes into a PR title and body that match the project's existing conventions. Analyze git history and diffs for intent, not just file names. ## Use this skill when - Writing or drafting a pull request description for the current branch - Generating a PR title that matches the project's commit/PR style - Filling in a PR template based on actual code changes ## Do not use this skill when - The request is to actually open or push a pull request - There are no commits ahead of the base branch - The user only wants a commit message, not a PR description **This skill is read-only. Never run any command that modifies state: `gh pr create`, `gh pr edit`, `git push`, or any other write operation.** ## Context The user wants a ready-to-use PR title and body based on what changed in the current branch. Focus on **intent and impact**, not raw diff output. Respect the project's existing PR style. ## Instructions ### Step 1: Detect Base Branch If `$ARGUMENTS` is provided, use it as the base branch. Otherwise, auto-detect in this order: 1. Run `git symbolic-ref refs/remotes/origin/HEAD 2>/dev/null` — extract branch name (e.g., `origin/main` → `main`) 2. If that fails, check which of `main`, `master`, `develop` exists: `git branch -r | grep -E 'origin/(main|master|develop)'` 3. Use the first match found ### Step 2: Collect Change Information Run these commands in order: ```bash git log <base>..<HEAD> --oneline git diff <base>...<HEAD> --sta...

Details

Author
2ykwang
Repository
2ykwang/agent-skills
Created
6 months ago
Last Updated
2 weeks ago
Language
Python
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category