Skip to content
Agentmart
Submit a tool

github-pr

Prepare and create a high-quality GitHub Pull Request for the current branch

Skill by javierponferradalopez

IndexedMIT
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/javierponferradalopez-github-pr

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Prepare and create a high-quality GitHub Pull Request for the current branch

Use cases: productivity

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/github-pr

What's inside

Skill name
github-pr
Description
Prepare and create a high-quality GitHub Pull Request for the current branch
License
MIT
Instructions
19 lines in SKILL.md · view on GitHub

Files (2)

  • PR_FORMAT.md
  • SKILL.md

SKILL.md (first lines)

# GitHub PR

Prepare a Pull Request for the current branch: infer the business *why* from the changes, and always present a preview for approval before creating anything.

## Procedure

1. **Gather context.** Run the commands; if one fails, say what's missing and ask only for that. Stop if it's not a git repo, `gh` isn't authenticated (surface the fix, e.g. `gh auth login`), or there are zero commits over the base (confirm the base).
   - **Repo & branch**: `git rev-parse --abbrev-ref HEAD`. Detect base: `git symbolic-ref refs/remotes/origin/HEAD | sed 's@^refs/remotes/origin/@@'`, falling back to `main`, then `master`.
   - **Merge base**: `MB=$(git merge-base origin/$BASE HEAD)` (fetch origin first if needed).
   - **Changed files**: `git diff --name-only $MB..HEAD`, grouped by logical component.
   - **Commits**: `git log $MB..HEAD --no-merges` — take the dominant Conventional-Commits type/scope for the title, and infer problem + solution from the changes. Never list the commits one by one.
   - **Stacked PR**: a parent-PR reference in commits or branch-naming convention. If stacked, base on the previous branch and reference the related PRs.
   - **Linked issue**: if `docs/agents/issue-tracker.md` exists, it defines the project's tracker and how a ticket is referenced and fetched. Look for a reference in the user's input, the commit messages, and the branch name; if found, fetch the ticket and infer **Problem** from its stated need. Otherwise infer **Problem** from the commits and diff.
2. **Draft the title + description strictly against [`PR_FORMAT.md`](./PR_FORMAT.md)** — open it every run, don't draft from memory.
3. **Present the preview**: *"Review the PR draft. Reply `approve` to proceed or `edit:` with changes."* Never create the PR without explicit approval.
4. **On `approve`**: `gh pr create --draft --assignee @me --title "<TITLE>" --body "<DESCRIPTION>"`, adding `--base <previous-branch>` only when stacked. Remove `--draft` only when the user asks for a PR that is ready for review. Print the PR URL.
5. **On `edit:`**: apply the edits to the title/description only, re-show the preview, wait for `approve`.

From javierponferradalopez/skills, MIT.

More from javierponferradalopez/skills

Signals

Stars
0
Forks
0
Open issues
1
Last commit (this folder)
Oct 15, 2026 (14 days ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from javierponferradalopez

Cite this page

github-pr skill. Agent Mart. https://agentmart.dev/skills/javierponferradalopez-github-pr (last updated 2026-10-24)