create-pr

A procedure for creating a pull request from the current Git branch. A pull request is a request to review and merge code into the project's default branch.

In plain words
What is it for?
Preparing a branch for review, checking its commits and changed files, and opening a GitHub pull request.
Why use it?
It standardizes branch checks, commit and repository inspection, and pull-request creation while protecting the default branch from direct commits.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/fpindej/netrock/create-pr
Any agent
npx skills add fpindej/netrock --skill create-pr
Clone the repo
git clone --depth 1 https://github.com/fpindej/netrock

Made for: Claude Code, Codex.

Per session 8 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 706 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00008 $0.00706
Opus 5 $0.00004 $0.00353
Sonnet 5 $0.00002 $0.00141
Haiku 4.5 $0.00001 $0.00071

Measured 2d ago against content hash d50c378bd59d, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, 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 2d 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.

.claude/skills/create-pr/SKILL.md · 57 lines

How it starts

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

Creates a pull request for the current branch.

Current Branch Context

Branch: !git branch --show-current

Default branch: !git symbolic-ref --short refs/remotes/origin/HEAD 2>/dev/null | sed 's|origin/||' || gh repo view --json defaultBranchRef --jq .defaultBranchRef.name 2>/dev/null || echo "master"

Commits on this branch: !git log $(git symbolic-ref --short refs/remotes/origin/HEAD 2>/dev/null || echo origin/master)..HEAD --oneline 2>/dev/null || echo "(no commits ahead of the default branch)"

Files changed: !git diff --stat $(git symbolic-ref --short refs/remotes/origin/HEAD 2>/dev/null || echo origin/master) 2>/dev/null || echo "(no diff from the default branch)"

Hard rules

  • Never commit on the default branch (master or main - see context above). If on it, create a branch first. No exceptions.
  • No Co-Authored-By lines in commits. User mentions Claude on PRs, not on individual commits.
  • Commit signing follows the developer's git config (commit.gpgsign) - never pass -S explicitly; fresh clones may have no signing key.
  • Session docs are immutable history - never update old session docs to reflect current state.

Steps

  1. Check git status - if uncommitted changes exist, commit them first (infer message from changes)
  2. Verify you are NOT on the default branch. If you are, stop and ask the user to create a branch.
  3. Review all branch commits: git log {default-branch}..HEAD --oneline
  4. Push if needed: git push -u origin $(git branch --show-current)

Session documentation (auto-generate for non-trivial PRs - 3+ commits or 5+ files changed):

  1. Create docs/sessions/{YYYY-MM-DD}-{topic-slug}.md per docs/sessions/README.md:
    • Summarize all commits on the branch
    • List files changed with reasons
    • Document key decisions and reasoning
    • Add follow-up items if any
  2. Commit: docs: add session notes for {topic}
  3. Push again

Create PR:

  1. Create PR with gh pr create using the PR body template:
    • Title: Conventional Commit format, under 70 chars
    • Base: argument if provided, otherwise the default branch
    • Labels: Apply all relevant (backend, frontend, feature, bug, security, documentation)
  2. Merge strategy for this project: squash-and-merge only
  3. Report PR URL

Read the full file on GitHub · 57 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 2d ago First seen · 57 lines · 8 tokens per session scan A d50c378bd59d

Subscribe to this mod's changes

create-pr is a skill published in the GitHub repository fpindej/netrock (231 stars, last pushed 3d ago), licensed MIT. It adds 8 tokens to every session and 706 once invoked, about $0.0000 per session on Opus 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-30.