From pull-request
Creates pull requests, merge requests, or change requests with proper formatting. Gathers git context, detects review bots, and applies commit style conventions.
How this skill is triggered — by the user, by Claude, or both
Slash command
/pull-request:create [--draft] [--auto] [--watch] [--dry-run][--draft] [--auto] [--watch] [--dry-run]This skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
- Remote URL: !`git remote get-url origin`
git remote get-url originbun ${CLAUDE_PLUGIN_ROOT}/scripts/detect-bot.tsbun ${CLAUDE_PLUGIN_ROOT}/scripts/pr-template.ts!bun ${CLAUDE_PLUGIN_ROOT}/scripts/git-context.ts
!bun ${CLAUDE_PLUGIN_ROOT}/scripts/contributing.ts
${subject}: ${summary} (e.g., api: add timeout to request)${type}: ${summary} (e.g., fix: add timeout to request)The body conveys what the diff cannot: why this change, what you decided along the way, and how you know it works. The reviewer reads the diff for what changed, so don't restate it. Spend the body on intent and the decisions a reviewer can't reconstruct from the code.
Mine the conversation that produced this change. The substance lives there: decisions and the alternatives you rejected, the scope you added or dropped, theories you tried and overturned, what you observed testing locally, limitations you ruled out, naming or scope you settled by hand. Put it in the body as a self-contained decision, not as a delta against a plan the reviewer never saw. Keep it out of code comments.
## sections only when the body is long enough to need them. Small PRs are a tight paragraph with no headers.Closes #N, Fixes #N, or #N if not closing). Related-for-context issues go in a ## References section, never bare at the bottom.#N, !N, owner/repo#N). Backticks render them as code and kill the link. Write them bare.See sections.md for the substance catalog (what to surface, by change type), optional-section guidance, how to ground claims in evidence, and the slop patterns to cut. Load the writing skill for the full set of tropes to avoid.
A wall of text is easier to prevent than to fix. For a large change, or any open-source PR, settle the structure before writing prose.
When a PR template is provided in context above, follow its structure instead of the default body format:
<!-- ... -->) that serve as placeholder instructions## Changes guidance in sections.md## Testing guidance in sections.md## References contentsections.mdWhen no template is detected, use the default body format from the Body section above.
When an issue is referenced:
Closes #123, Fixes #456)Reviewer suggestion is for corporate and internal work. On OSS the project author or maintainer triages incoming PRs, so suggesting reviewers there only adds noise. Gate this whole section on repository visibility:
gh repo view --json visibility -q .visibilityglab api projects/:fullpath --jq .visibilityA public repository is OSS. Skip the rest of this section and let the maintainer triage. Any other visibility (private, internal) is corporate. Continue below.
Suggest reviewers; never assign them. The user always chooses from the suggestions.
Run the script to rank candidates from the git history of the changed files. It excludes you and needs no arguments:
bun ${CLAUDE_PLUGIN_ROOT}/scripts/suggest-reviewers.ts
This runs after you create the PR/MR, so it never delays creation. Resolve names to platform usernames only after the user accepts, then assign them to the existing PR/MR:
gh pr edit --add-reviewer <user> (resolve emails to logins with mcp__github if needed)gitlab:merge-request for username resolution, then glab mr update --reviewer <user>Parse $ARGUMENTS for these flags. With none, create a normal PR/MR that is ready for review and does not auto-merge.
--draft: open the PR/MR as a draft. Default: ready for review.--auto: after creating, enable auto-merge so it merges once checks pass and required approvals land. Default: off.--watch: after creating, spawn pull-request:babysit to actively shepherd the PR/MR (fix trivial red CI, drive the merge). When a bot review should gate the merge (asked to wait for a reviewer, or a review bot is configured on the repo), add --reviews so babysit hands the wait to follow-up --auto, which reads each reviewer's documented signal before merging. At creation time the pending-status-check signal does not exist yet, so lean on the configured-reviewer signal here and let follow-up re-check the live PR; a needless --reviews costs only one no-op hand-off. Distinct from --auto, which only flips on the platform's passive auto-merge. Default: off.--dry-run (alias --body-only): produce the body without creating anything. See Dry Run. Default: off.If the arguments include --dry-run (alias --body-only), produce the body without creating anything. Determine the title and body from the context above as usual, write the body to tmp/pr-body-<branch>.md, then print the title and body to the user and stop. Do not stage, commit, push, or run gh pr create / glab mr create. Use this to preview or evaluate the body in isolation.
If --dry-run (or --body-only) is set, follow the Dry Run section instead of the steps below.
git add .git commit -m "..."pull-request:follow-up --local before pushing so its findings surface while the branch is still local. With no config, a bot may still review the repo: follow-up's local.md hosted signals decide. Skip when a local bot pass already ran on this branch in this session (/ship runs it as a gated pass), when detection comes up empty, or when the user declines.git push -u origin HEAD--draft to the create command when --draft is set:
tmp/pr-body-<branch>.md)gh pr create --title "..." --body-file tmp/pr-body-<branch>.mdglab mr create --title "..." --description "$(cat tmp/pr-body-<branch>.md)"--auto is set, after the PR/MR exists:
gh pr merge --auto (add --squash or --rebase to match the repo's merge method when known)gitlab:merge-request and run its merge.ts --auto-merge, which handles merge trains and falls back to glab mr merge as needed--watch is set. Spawn a background Agent that invokes the pull-request:babysit <url> --merge skill (add --reviews when a bot review should gate the merge, per the flag above) on the PR/MR url created earlier. Babysit is session-scoped and owns its own Monitor watcher, so running it inside a backgrounded Agent gives it a session to live in: the create session returns immediately while the watch persists in the background. This mirrors the babysit -> follow-up handoff, where babysit delegates the review loop to another skill that owns its own watchers.For advanced GitLab features (stacking, username lookup), load gitlab:merge-request.
npx claudepluginhub bendrucker/claude --plugin pull-requestCreates, updates descriptions, and adds comments to GitHub pull requests using file-based drafts for safety, emphasizing material impact and reviewer-friendly communication.
Creates pull requests following Sentry's engineering practices, generating structured descriptions with what changed, why, and reviewer context. Requires GitHub CLI.
Crée automatiquement des Pull Requests GitHub avec analyse des modifications, modèle et labels, via `gh` et `git`.