Merging PRs
PostHog/posthog
Merge a PR into master through the Trunk merge queue and babysit it until it lands.
Merge a PR into main through the Trunk merge queue and babysit it until it lands.
$ npx skills add PostHog/code --skill merging-prs -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install PostHog/code merging-prs --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/merging-prs .claude/skills/merging-prs && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "merging-prs" agent skill from https://github.com/PostHog/code/tree/main/.claude/skills/merging-prs into .claude/skills/merging-prs/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "merging-prs", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/PostHog/code/tree/main/.claude/skills/merging-prsType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add PostHog/code --skill merging-prs -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install PostHog/code merging-prs --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.claude/skills/merging-prs .agents/skills/merging-prs && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "merging-prs" agent skill from https://github.com/PostHog/code/tree/main/.claude/skills/merging-prs into .agents/skills/merging-prs/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "merging-prs", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add PostHog/code --skill merging-prs -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install PostHog/code merging-prs --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.claude/skills/merging-prs .cursor/skills/merging-prs && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "merging-prs" agent skill from https://github.com/PostHog/code/tree/main/.claude/skills/merging-prs into .cursor/skills/merging-prs/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "merging-prs", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/PostHog/code.git --path .claude/skills/merging-prs--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add PostHog/code --skill merging-prs -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install PostHog/code merging-prs --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.claude/skills/merging-prs .gemini/skills/merging-prs && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "merging-prs" agent skill from https://github.com/PostHog/code/tree/main/.claude/skills/merging-prs into .gemini/skills/merging-prs/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "merging-prs", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install PostHog/code merging-prsInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add PostHog/code --skill merging-prs -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .github/skills && cp -r skills-src/.claude/skills/merging-prs .github/skills/merging-prs && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "merging-prs" agent skill from https://github.com/PostHog/code/tree/main/.claude/skills/merging-prs into .github/skills/merging-prs/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "merging-prs", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add PostHog/code --skill merging-prs -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install PostHog/code merging-prs --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.claude/skills/merging-prs .opencode/skills/merging-prs && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "merging-prs" agent skill from https://github.com/PostHog/code/tree/main/.claude/skills/merging-prs into .opencode/skills/merging-prs/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "merging-prs", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
merging-prsMerge a PR into main through the Trunk merge queue and babysit it until it lands.
Merging PRs is an agent skill from PostHog/code, published by the product's own GitHub organization. Merge a PR into main through the Trunk merge queue and babysit it until it lands. Enqueue with a "/trunk merge" comment, then poll the "Trunk Merge Queue" check run and the PR state until it is MERGED or FAILED, reporting the Trunk bot's failure reason if the PR is kicked out. Use when asked to merge a PR, "merge when ready", "land it", "ship it", or to babysit/watch a PR through the queue. Never use gh pr merge in this repo -- the queue is the only path into main.
Its SKILL.md is about 1.3k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
The repository describes itself as: The era of self-driving development is here. The licence is MIT.
5 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit a4c32df. It shows what the files ask for, not the result of running them.
Pre-approves these tools, so the agent can use them without asking each time:
Bash(gh pr view:*)Bash(gh pr checks:*)Bash(gh pr comment:*)Bash(gh pr ready:*)Bash(gh api:*)Bash(sleep:*)From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
ghFrom the folder's file list and the shell code blocks in SKILL.md.
Links to these hosts (documentation or services it may open):
trunk.ioFrom URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Merging PRs loads about 1.3k tokens when it runs. Until then it costs about 121 tokens; SKILL.md has 616 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from PostHog/code at commit a4c32df, republished under its MIT licence (© PostHog). 616 words, ~1,338 tokens.
.claude/skills/merging-prs/SKILL.md (or your agent's skills folder).Merges into main go exclusively through the Trunk merge
queue. gh pr merge and the GitHub merge button are blocked by branch ruleset.
To merge, you enqueue the PR with a comment, then watch it until Trunk lands it.
When a developer says "merge this PR", "merge it when it's ready", "land it", "ship it", or "babysit this PR", do the full loop below — enqueue and watch to completion, reporting the outcome.
<n> below is the PR number. Resolve the repo slug once if you need it:
REPO=$(gh repo view --json nameWithOwner -q .nameWithOwner).
gh pr view <n> --json state,isDraft,mergeable,reviewDecision,statusCheckRollupgh pr ready <n> before continuing. Don't un-draft silently.statusCheckRollup) → the queue will just reject
it. Report which checks are red and stop; fix them first. Pending checks
are fine — the queue waits for them.reviewDecision empty or REVIEW_REQUIRED) → fine,
enqueue anyway. See below.mergeable == "CONFLICTING") → report and stop; rebase first.Enqueueing before approval is safe, and is the closest thing this repo has to
auto-merge. A submitted PR sits in Trunk's Queued state until GitHub's branch
protection on main is satisfied — one approving review, code-owner review, and
the required checks (build, quality, unit-test, integration-test,
typecheck) — and Trunk merges it once they land. Trunk is not a bypass actor on
those rules, so it cannot merge an unapproved or red PR.
The catch: pushing new commits drops the PR from the queue. If review
feedback is likely, either wait for approval before enqueueing, or re-enqueue
with /trunk merge after each push.
gh pr comment <n> --body "/trunk merge"Within ~2 minutes, confirm Trunk picked it up — a check run whose name starts
with Trunk Merge Queue should appear on the head commit:
SHA=$(gh pr view <n> --json headRefOid -q .headRefOid)
gh api repos/$REPO/commits/$SHA/check-runs \
--jq '.check_runs[] | select(.name | startswith("Trunk Merge Queue")) | {name, status, conclusion, details_url}'If nothing appears after a couple of minutes, the developer may lack write
access or GitHub-comment commands may be disabled — report that and suggest the
trunk-merge-queue-submit label as a fallback.
Loop about every 60 seconds, up to ~45–60 minutes total. Each iteration:
gh pr view <n> --json state,mergedAt # MERGED -> success, stop
SHA=$(gh pr view <n> --json headRefOid -q .headRefOid)
gh api repos/$REPO/commits/$SHA/check-runs \
--jq '.check_runs[] | select(.name | startswith("Trunk Merge Queue")) | {status, conclusion, details_url}'
sleep 60state == "MERGED" → done. Report success with the merge commit.status moves queued → in_progress → completed. Report each
transition so the developer can follow along.gh pr checks --watch: the queue runs
CI on Trunk's own draft/trunk-merge/** branch, so this PR's own checks don't
reflect the queue's testing.Queued waiting on a human review, say so once and slow the
cadence to ~5 minutes. Keep watching — the merge still has to be reported.If the check run completes with conclusion == "failure" (or the PR drops out
of the queue), Trunk kicks the PR and its bot comments with the failing
workflow. Read the newest comments and report the reason:
gh pr view <n> --comments | tail -n 40/trunk merge.If the developer asks to stop the merge:
gh pr comment <n> --body "/trunk cancel"Confirm the check run reports cancelled.
gh pr merge — it's blocked and it's not how this repo merges.© PostHog, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in .claude/skills/merging-prs of PostHog/code.
Open the folder on GitHubat commit a4c32df
Merging PRs next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Merging PRs this skillPostHog/code | 179 | — | ~1.3k | Automated safety check: Pass | MIT | |
| Merging PRsPostHog/posthog | 40k | — | ~4.1k | Automated safety check: Pass | Custom licence | |
| Merge Dependabot PRsonyx-dot-app/onyx | 32k | 1 repos | ~2.2k | Automated safety check: Pass | MIT | |
| Triaging Merge Queue FailuresPostHog/posthog | 40k | — | ~9.5k | Automated safety check: Pass | Custom licence | |
| Archestra Merge Queuearchestra-ai/archestra | 4.4k | — | ~2.3k | Automated safety check: Pass | Custom licence | |
| Mergewithastro/astro | 63k | — | ~153 | Automated safety check: Pass | Custom licence |
PostHog/posthog
Merge a PR into master through the Trunk merge queue and babysit it until it lands.
onyx-dot-app/onyx
Triages and lands a batch of open Dependabot PRs in the Onyx repo, where main is gated exclusively by GitHub's merge queue: approves and enqueues green PRs, closes superseded duplicates, fixes…
PostHog/posthog
Decision procedure for a PR that failed or was removed from the Trunk merge queue: classify the kick (superseded by a newer commit, not mergeable, a gate that failed on a cancelled run, real…
archestra-ai/archestra
A skill your agent uses when asked to add an Archestra PR to the merge queue, monitor it through merge, or diagnose and repair merge-group CI failures.
withastro/astro
Handle main-to-next merge tasks including conflict resolution, changeset cleanup, and CI fix-ups.
dotnet/dotnet-docker
Create a PR to merge main into the nightly branch after a .NET containers release.
PostHog/code
How PostHog "canvas" dashboards work end-to-end — the two rendering tiers (json-render vs freeform React-in-iframe), the agent system prompts that steer each, and the RIGHT way to fetch PostHog data…
PostHog/code
How to write JavaScript workflow scripts for the workflow tool - fanning work out across many isolated subagents with agent(), parallel(), and pipeline(), then synthesizing one result.
PostHog/code
Install, configure, authenticate, and troubleshoot MCP (Model Context Protocol) servers for this agent.
PostHog/code
Add, replace, and optimize the looping demo videos in the onboarding "welcome" bento grid (packages/ui/src/features/onboarding).
PostHog/code
Edit the @posthog/quill design system locally and consume the change in this repo (posthog-code) before it is published to npm.
PostHog/code
Write Storybook stories for PostHog UI components. An agent skill from PostHog/code.
Merge a PR into main through the Trunk merge queue and babysit it until it lands. Merging PRs is an agent skill from PostHog/code, published by the product's own GitHub organization. Merge a PR into main through the Trunk merge queue and babysit it until it lands.
Merging PRs fits situations like: asked to merge a PR; merge when ready; babysit/watch a PR through the queue.
Run `npx skills add PostHog/code --skill merging-prs -a claude-code`. Or copy the skill folder (.claude/skills/merging-prs in PostHog/code) into .claude/skills/merging-prs in your project. Claude Code loads it when a task matches its description.
Run `npx skills add PostHog/code --skill merging-prs -a codex`. Or copy the skill folder (.claude/skills/merging-prs in PostHog/code) into .agents/skills/merging-prs in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add PostHog/code --skill merging-prs -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/merging-prs, .gemini/skills/merging-prs, .github/skills/merging-prs and .opencode/skills/merging-prs in your project.
Going by SKILL.md and its folder, Merging PRs needs the command-line tools its instructions call (gh). Its frontmatter pre-approves these tools: Bash(gh pr view:*), Bash(gh pr checks:*), Bash(gh pr comment:*), Bash(gh pr ready:*), Bash(gh api:*), Bash(sleep:*).
SKILL.md names 1 domain. As links in the text: trunk.io. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Merging PRs is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.3k tokens (SKILL.md is roughly 5.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Merging PRs: Merging PRs (PostHog/posthog, 40k stars), Merge Dependabot PRs (onyx-dot-app/onyx, 32k stars), Triaging Merge Queue Failures (PostHog/posthog, 40k stars) and Archestra Merge Queue (archestra-ai/archestra, 4.4k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
PostHog (a GitHub organization, an official publisher) maintains it in PostHog/code, which has 179 GitHub stars. The repository holds 10 skills in this directory. The repository was last updated on August 5, 2026.
Source: PostHog/code on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.