commit-push-pr
Skill1 starsChanged 8 months agoMITView on GitHub
Commit staged changes, push to remote, and create a pull request — all in one step. Usage: /commit-push-pr [description]
- Reads credentials
- Commits and pushes
12 other projects use a version of this.
Adopted by
Most recently taken up by
- converge-ai-labs/agent-foundationtheir own version, first seen Sep 30, 2026
- ZunoSmartLabs/zsl-superpowerstheir own version, first seen Sep 21, 2026
- congmnguyen/claude-code-wsl2-setuptheir own version, first seen Sep 8, 2026
- dceoy/ai-coding-agent-skillstheir own version, first seen Sep 6, 2026
- cmacnichol/skillstheir own version, first seen Jul 31, 2026
- jh941213/my-cc-harnesstheir own version, first seen Jul 27, 2026
Used with
Projects with it also use simplify, commit and 3 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
Hugging FaceSkillsimplify
Refactor code after tests pass. The "Refactor" phase of Red-Green-Refactor.
Also in 3 projects that use this
SentrySkillcommit
Create commit messages following Sentry conventions. Use when committing code changes, writing commit messages, or formatting git history. Follows conventional commits with Sentry-specific issue references.
Also in 4 projects that use this
OpenAISkillsystematic-debugging
Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes
Also in 3 projects that use this
AWSSkilltdd
Test-driven development. Use when the user wants to build features or fix bugs test-first, mentions "red-green-refactor", or wants integration tests.
Also in 3 projects that use this
MicrosoftSkillhandoff
Compact the current conversation into a handoff document for another agent to pick up.
Also in 3 projects that use this
Other versions12 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 12
- llama-farm/llamafarm★ 837same name
- converge-ai-labs/agent-foundation★ 143same name
- jh941213/my-cc-harness★ 126same name
- sneg55/agent-starter★ 76same name
- congmnguyen/claude-code-wsl2-setup★ 50same name
- dceoy/ai-coding-agent-skills★ 4same name
- wangyiyang/dev-agent-skills★ 4same name
- ZunoSmartLabs/zsl-superpowers★ 2same name
- arkan/skills★ 1same name
- renatorozas/claude-code-config★ 1same name
2 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
The file
We split this skill into the rules it gives an agent
11 rules. 0 are common, 10 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 11 edited versions we read keep these.
10
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Distinctive: line 16
Create a well-crafted commit
- Distinctive: line 20
If the user provides a description, use it to guide the commit message and PR body.
- Distinctive: line 28
Run these in parallel:
- Distinctive: line 43
If there are unstaged changes that look intentional (not build artifacts), stage them.
- Distinctive: line 47
Read the project's CLAUDE.md for PR conventions (e.g., "PRs target develop" or "PRs target main").
- Distinctive: line 57
If there are uncommitted changes to include:
- Distinctive: line 61
Follow the repo's existing commit style (conventional commits, etc.)
- Distinctive: line 62
Do not commit files that likely contain secrets (.env, credentials)
- Distinctive: line 74
If everything is already committed, skip to Step 4.
- Distinctive: line 82
If the branch doesn't exist on remote yet, this creates it.
- Very specific: line 101
Use the base branch determined in Step 2 (e.g., --base develop).
“Common” is measured: kept by at least 6 in 10 of the 11 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Commit, Push & PR
One command to go from local changes to a pull request.
How It Works
The user invokes /commit-push-pr [optional description]. You then:
- Review all changes
- Create a well-crafted commit
- Push to remote
- Open a pull request
If the user provides a description, use it to guide the commit message and PR body. If not, derive everything from the diff.
Process
Step 1 — Review Changes
Run these in parallel:
git status
git diff --cached --stat
git diff --stat
git log --oneline -5
git branch --show-currentUnderstand:
- What branch you're on
- What's staged vs unstaged
- Recent commit style for message consistency
If there are unstaged changes that look intentional (not build artifacts), stage them. Ask the user if unclear.
Step 2 — Determine Base Branch
Read the project's CLAUDE.md for PR conventions (e.g., "PRs target develop" or "PRs target main"). If no convention is documented, default to main.
git log --oneline main..HEAD 2>/dev/null || git log --oneline origin/main..HEAD 2>/dev/nullReview ALL commits that will be in the PR, not just the latest.
Step 3 — Commit
If there are uncommitted changes to include:
- Analyze all changes (staged + newly added)
- Draft a concise commit message: 1-2 sentences focusing on the "why"
- Follow the repo's existing commit style (conventional commits, etc.)
- Do not commit files that likely contain secrets (.env, credentials)
git add <relevant files>
git commit -m "$(cat <<'EOF'
<commit message>
Co-Authored-By: Claude <noreply@anthropic.com>
EOF
)"If everything is already committed, skip to Step 4.
Step 4 — Push
git push -u origin HEADIf the branch doesn't exist on remote yet, this creates it.
Step 5 — Create PR
Analyze ALL commits between base branch and HEAD to write the PR:
gh pr create --title "<short title, under 70 chars>" --body "$(cat <<'EOF'
## Summary
<1-3 bullet points covering all commits in this PR>
## Test plan
- [ ] <verification steps>
🤖 Generated with [Claude Code](https://claude.ai/code)
EOF
)"Use the base branch determined in Step 2 (e.g., --base develop).
Step 6 — Report
Show the PR URL. Keep it brief.
Rules
- Read CLAUDE.md first — check for PR conventions (base branch, commit style, CI requirements)
- All PR text in English — titles, descriptions, commit messages
- Don't skip the review — always look at the full diff before committing
- Never force push — if push fails, diagnose and tell the user
- Never commit secrets — skip .env, credentials, API keys
- Use
ghCLI — not MCP GitHub tools - Keep it fast — this is a workflow accelerator, not a code review
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

