commit-push-pr

A workflow that commits code changes, pushes them to a remote Git repository, and opens a pull request, which is a request for others to review and merge changes. It can create a working branch and handle signed commits.

In plain words
What is it for?
Use it when you want to ship a completed change from your local repository through commit, push, and pull-request creation.
Why use it?
It combines the routine steps of preparing code for review into one process. It also avoids making changes directly on the main branch when a separate branch is needed.

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/pigfoot/claude-code-hubs/commit-push-pr
Any agent
npx skills add pigfoot/claude-code-hubs --skill commit-push-pr
Clone the repo
git clone --depth 1 https://github.com/pigfoot/claude-code-hubs

Made for: Claude Code, Codex.

Per session 51 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 940 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.00051 $0.00940
Opus 5 $0.00026 $0.00470
Sonnet 5 $0.00010 $0.00188
Haiku 4.5 $0.00005 $0.00094

Measured 2d ago against content hash 1cb27cace5ad, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

commit-push-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.

plugins/commit/skills/commit-push-pr/SKILL.md · 143 lines

How it starts

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

Commit Push PR Skill

Commits staged/unstaged changes, pushes to remote, and creates a pull request in a single workflow.

Context

  • Current git status: !git status
  • Current git diff (staged and unstaged): !git diff HEAD
  • Current branch: !git branch --show-current
  • Recent commits: !git log --oneline -10

Process

⚠️ CRITICAL: ALWAYS start with Step 1 (Environment Check) before attempting any commit

1. Environment Check (MANDATORY FIRST STEP)

Cache GPG passphrase if available:

if [ -n "$GPG_PASSPHRASE" ]; then
  gpg --batch --pinentry-mode loopback \
      --passphrase-file <(echo "$GPG_PASSPHRASE") \
      --clearsign >/dev/null 2>&1 <<< "test" && echo "GPG passphrase cached" || echo "GPG cache failed"
else
  echo "GPG_PASSPHRASE not set - GPG signing will prompt for passphrase"
fi

2. Branch Check

If currently on main or master, create a new branch first:

git checkout -b <descriptive-branch-name>
  • Name based on changes: feat/add-auth, fix/login-bug, docs/update-readme
  • Use a prefix matching the intended commit type

3. Analyze Changes

Use the context injected above (git status, diff, branch):

  • Prefer staged files if any exist; otherwise stage all changes with git add
  • For this skill: single commit only — if multi-concern, inform user and let them decide before proceeding

4. Create Commit

git add <relevant-files>
git commit --signoff --gpg-sign -m "<type>: <description>"

Conventional commit format: <type>: <description> (imperative mood, <72 chars)

5. Push

git push -u origin HEAD

6. Create PR

gh pr create --title "<commit-message>" --body "$(cat <<'EOF'
## Summary
- <key change 1>
- <key change 2>

## Test plan
- [ ] Verify <main behavior>
EOF
)"
  • PR title = commit message (same text)
  • Body: bullet summary of changes + basic test checklist
  • Return the PR URL to the user

Commit Types

Type Use Case
feat New feature
fix Bug fix
docs Documentation
style Formatting, styling
refactor Code restructure
perf Performance
test Tests
chore Build/tools
ci CI/CD
security Security fix
build Build system

Read the full file on GitHub · 143 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. 2d ago First seen · 143 lines · 51 tokens per session scan A 1cb27cace5ad

Subscribe to this mod's changes

commit-push-pr is a skill published in the GitHub repository pigfoot/claude-code-hubs (5 stars, last pushed 1mo ago), licensed MIT. It adds 51 tokens to every session and 940 once invoked, about $0.0003 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-31.