merge-pr
Skill877 starsChanged 6 days agoMITView on GitHub
Merge a GitHub PR by fast-forwarding main to its head, so every commit lands unchanged with its signature and no merge commit is created
- Commits and pushes
18 other projects use a version of this.
Adopted by
Most recently taken up by
- kratocz/skillstheir own version, first seen Nov 15, 2026
- kdy1/kdy1-scriptstheir own version, first seen Nov 15, 2026
- developerz-ai/open-mmorpgtheir own version, first seen Nov 10, 2026
- ddnexus/pagytheir own version, first seen Nov 9, 2026
- ShareX/ShareXtheir own version, first seen Nov 8, 2026
- r3bl-org/r3bl-open-coretheir own version, first seen Oct 17, 2026
Used with
Projects with it also use implement-issue, create-pr and 1 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.
GoogleSkillimplement-issue
Implement a Site Kit GitHub issue end-to-end from its implementation brief. Use when the user asks to implement, build, or work on a GitHub issue / feature by number (e.g. "implement issue #12345", "build the feature in issue 12345", "follow the implementation brief for #12345") in the google/site-kit-wp repo.
Also in 3 projects that use this
SentrySkillcreate-pr
Create pull requests following Sentry conventions. Use when opening PRs, writing PR descriptions, or preparing changes for review. Follows Sentry's code review guidelines.
Also in 7 projects that use this
sahinSkillcreate-issue
Also in 3 projects that use this
Other versions18 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 18
- ShareX/ShareX★ 41ksame name
- cube-js/cube★ 21ksame name
- ddnexus/pagy★ 5ksame name
- bazel-contrib/rules_python★ 695same name
- kkokosa/dotLLM★ 528same name
- r3bl-org/r3bl-open-core★ 486same name
- tbhb/vale-ai-tells★ 118same name
- TermiX-official/cryptoclaw★ 100same name
- kdy1/kdy1-scripts★ 34same name
- neul-labs/openclawMU★ 33same name
8 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.
In this repository10 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- changelogSkill
- commitSkill
- pre-commitSkill
- release-libsSkill
- release-mcpSkill
- release-openclaw-skillSkill
- review-loopSkill
- update-maturinSkill
- verify-device-supportSkill
The file
We split this skill into the rules it gives an agent
8 rules. 0 are common, 3 are distinctive, and 5 are very specific to this project.
0
Common
Most of the 18 edited versions we read keep these.
3
Distinctive
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 14
Run every check before touching anything.
- Very specific: line 33
If it is not a descendant of origin/main, stop.
- Very specific: line 42
Every commit must show true.
- Very specific: line 46
Every entry in statusCheckRollup must have concluded SUCCESS, NEUTRAL or SKIPPED, and the required checks Rust / Checks and Rust / Checks …
- Very specific: line 50
If reviewDecision is not APPROVED, ask the user to confirm, then run gh pr review <N> --approve.
- Distinctive: line 58
Wait for explicit confirmation.
- Very specific: line 66
Never use --force. If the push is rejected because main moved, stop and report it.
- Distinctive: line 78
If the current branch is main and the working tree is clean, run git pull --ff-only.
“Common” is measured: kept by at least 6 in 10 of the 18 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
Merge PR
Merge PR <N> by pushing its head commit to main as a fast-forward. GitHub's "Rebase and merge" rewrites commits without signing them, "Squash" collapses them, and "Merge commit" adds a merge commit, so none of the merge buttons fit.
Usage: /merge-pr <N>. If no number is given, ask for it.
Steps
Run every check before touching anything. On any failed check, stop and report it; do not work around it.
Read the PR
gh pr view <N> --json number,title,state,isDraft,baseRefName,headRefName,headRefOid,isCrossRepository,headRepositoryOwner,reviewDecision,statusCheckRollup,commitsstatemust beOPENandisDraftfalse.baseRefNamemust bemain.
Fetch the head and check it fast-forwards
maingit fetch origin main pull/<N>/head git rev-parse FETCH_HEAD # must equal headRefOid git merge-base --is-ancestor origin/main <headRefOid>If it is not a descendant of
origin/main, stop. Rebasing would replace the author's signatures, so ask the user whether to have the author rebase or to rebase and re-sign the commits themselves. Never rebase on your own.Verify every commit is signed
gh api repos/mihai-dinculescu/tapo/pulls/<N>/commits --paginate \ --jq '.[] | "\(.sha[0:7]) \(.commit.verification.verified) \(.commit.verification.reason) \(.commit.message | split("\n")[0])"'Every commit must show
true. GitHub's verification is the source of truth; a localgit log --show-signaturefails for keys not in the local keyring.Require green CI
Every entry in
statusCheckRollupmust have concludedSUCCESS,NEUTRALorSKIPPED, and the required checksRust / ChecksandRust / Checks on minimum supported versionmust be among them. If checks are still running, say so and stop; don't poll.Approve
If
reviewDecisionis notAPPROVED, ask the user to confirm, then rungh pr review <N> --approve. Approving is outward-facing, so never do it without the user's go-ahead.Confirm the push
Show the user:
- the commit list from step 3 (short SHA, subject, verified)
- the exact command:
git push origin <headRefOid>:refs/heads/main
Wait for explicit confirmation. Pushing to
maincannot be undone.Push
git push origin <headRefOid>:refs/heads/mainNever use
--force. If the push is rejected becausemainmoved, stop and report it; don't retry.Confirm the merge
gh pr view <N> --json state,mergedAt,mergeCommitstateshould beMERGEDandmergeCommit.oidshould equalheadRefOid. GitHub can take a few seconds to notice; check once more if it still showsOPEN, then report.Sync the local checkout
If the current branch is
mainand the working tree is clean, rungit pull --ff-only. Otherwise just tell the usermainmoved.Head branch
For a same-repo PR (
isCrossRepositoryfalse), ask whether to delete the head branch (git push origin --delete <headRefName>). Never delete it without asking. For a fork PR, leave it alone.
Notes
- Branch protection on
mainrequires an approving review and passing checks, butenforce_adminsis off, so an admin's direct push is accepted. Steps 4 and 5 enforce those requirements, since the push itself would skip them. - Issues referenced by the PR stay open until release; don't close them here.
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.

