create-pr

create-pr is a skill for Claude Code, Codex from shousper/claude-kit. It costs 86 tokens per session (814 once invoked), scanned A, original, MIT.

A workflow skill for creating GitHub pull requests from the current branch with the gh command-line tool. It checks the branch, detects pull-request templates, and creates a draft by default.

In plain words
What is it for?
Pushing a branch when needed, filling a repository pull-request template, and opening a draft or ready-for-review pull request.
Why use it?
It gathers the branch and repository details needed for a pull request and reduces the manual steps before opening one for review.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Pushing a branch when needed, filling a repository pull-request template, and opening a draft or ready-for-review pull request.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/shousper/claude-kit/create-pr
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add shousper/claude-kit --skill create-pr
Clone the repo
git clone --depth 1 https://github.com/shousper/claude-kit

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for create-pr

README.md
[![agentmods](https://agentmods.dev/badge/skills/shousper/claude-kit/create-pr/github.svg)](https://agentmods.dev/skills/shousper/claude-kit/create-pr)
Your own site
<a href="https://agentmods.dev/skills/shousper/claude-kit/create-pr"><img src="https://agentmods.dev/badge/skills/shousper/claude-kit/create-pr/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for create-pr

Your own site · 80×15
<a href="https://agentmods.dev/skills/shousper/claude-kit/create-pr"><img src="https://agentmods.dev/badge/skills/shousper/claude-kit/create-pr.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 86 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 814 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00086 $0.00814
Opus 5.5 $0.00034 $0.00326
Sonnet 5.5 $0.00017 $0.00163
Haiku 4.5 $0.00009 $0.00081

Measured 1mo ago against content hash 7257411eff0f, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

create-pr scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

shared/skills/create-pr/SKILL.md · 100 lines

How it starts

The opening of the file, as written. The whole thing — 100 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Create Pull Request

Overview

Create a pull request for the current branch. Defaults to draft so the author can review on GitHub before marking ready.

Core principle: Draft by default. The author controls when a PR is ready for review.

The Process

Step 1: Check Prerequisites

# Verify gh CLI is available and authenticated
command -v gh >/dev/null 2>&1 || echo "GitHub CLI (gh) not installed"
gh auth status 2>/dev/null || echo "Not authenticated with gh"

# Detect default branch
base=$(git symbolic-ref refs/remotes/origin/HEAD 2>/dev/null | sed 's@^refs/remotes/origin/@@')
base=${base:-main}
git log "origin/$base..HEAD" --oneline

# Verify branch is pushed
git rev-parse --abbrev-ref --symbolic-full-name @{u} 2>/dev/null

If branch is not pushed:

git push -u origin $(git branch --show-current)

Step 2: Detect PR Template

# Check common template locations
ls .github/PULL_REQUEST_TEMPLATE.md 2>/dev/null
ls .github/PULL_REQUEST_TEMPLATE/ 2>/dev/null
ls docs/PULL_REQUEST_TEMPLATE.md 2>/dev/null
ls PULL_REQUEST_TEMPLATE.md 2>/dev/null

If template exists: read it, fill out all sections from diff and commit history. If no template: examine recent merged PRs for conventions (gh pr list --state merged --limit 5).

Step 3: Create the PR

Default (draft):

gh pr create --draft --title "<title>" --body "<body>"

If your human partner explicitly requests "ready for review":

gh pr create --title "<title>" --body "<body>"

PR Content

  • Title: Short (under 70 chars), describes the change
  • Body: If using template, fill all sections. If no template:
    ## Summary
    <2-3 bullets of what changed and why>
    
    ## Test Plan
    - [ ] <verification steps>
    

Draft Override

Your human partner can request a non-draft PR by saying:

  • "ready for review"
  • "skip draft"
  • "mark it ready"
  • "not a draft"

In these cases, omit the --draft flag.

Common Mistakes

  • Hardcoding main as the base branch — always detect the default branch dynamically; some repos use master, develop, or other names.
  • Creating the PR before pushing the branch — gh pr create will fail if the branch doesn't exist on the remote.
  • Skipping the PR template — if the repo has one, fill it out completely. Reviewers expect it.
  • Writing vague titles — "Update code" or "Fix stuff" tells reviewers nothing. Describe the actual change.
  • Forgetting --draft — the default is draft for a reason. Only omit when your human partner explicitly asks.

Read the full file on GitHub · 100 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 100 lines · 86 tokens per session scan A 7257411eff0f

Subscribe to this mod's changes

create-pr is a skill published in the GitHub repository shousper/claude-kit (4 stars, last pushed 1mo ago), licensed MIT. It adds 86 tokens to every session and 814 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.