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.
npx agentmods add skills/posthog/posthog-foss/merging-prsnpx skills add PostHog/posthog-foss --skill merging-prsgit clone --depth 1 https://github.com/PostHog/posthog-fossWhat 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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00165 | $0.03025 |
| Opus 5 | $0.00082 | $0.01512 |
| Sonnet 5 | $0.00033 | $0.00605 |
| Haiku 4.5 | $0.00016 | $0.00302 |
Grade A, and why
merging-prs 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 today.
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.
How it starts
The opening of the file, as written. The whole thing — 162 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Merge a PR through the Trunk merge queue
Merges into master 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.
Required user approval
Before posting /trunk merge, invoking trunk merge, or re-enqueueing, obtain explicit user approval in the current conversation for the identified PR or stack. These actions can cause a PR to land. Never infer approval from a request to prepare a PR, move it toward merge, make it ready, resolve blockers, monitor it, or babysit it. You may inspect status, address reviews and CI, apply stamphog when approval is missing, and report that the PR is ready; then wait for a direct instruction to merge or enqueue it.
<n> below is the PR number.
Resolve the repo slug once if you need it: REPO=$(gh repo view --json nameWithOwner -q .nameWithOwner).
1. Preflight
gh pr view <n> --json state,isDraft,mergeable,reviewDecision,statusCheckRollup,baseRefName
- Not open (already merged/closed) → report and stop.
- Draft → it can't be merged. Ask the developer to confirm, then
gh pr ready <n>before continuing. Don't un-draft silently. - Failing required checks (
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. To work out why a check is red, use/debugging-ci-failures. - Merge conflicts (
mergeable == "CONFLICTING") → report and stop; mergemasterin first. - Missing approval (
reviewDecision == "REVIEW_REQUIRED", or a stamphog approval was dismissed) → apply thestamphoglabel yourself:gh pr edit <n> --add-label stamphog. That triggers the automated review-and-approve flow (tools/pr-approval-agent/README.md); on anAPPROVEDverdict the Stamphog app posts the approval that satisfies the required review. Re-applying the label is always safe and is the intended retry path — it gets stripped on aREFUSED/ESCALATEverdict, and after addressing that feedback you re-apply it to request a fresh review. Read the reason first: every verdict is its own review from the Stamphog app, opening with whether it approved. Re-applying the label without changing anything just repeats the same verdict. It stays sticky across ordinary pushes (non-trivial deltas re-review automatically), and it never works on bot-authored PRs. - Part of a stack (
baseRefName != "master", or the PR appears ingh api repos/$REPO/stacks) → the queue handles stacks natively: enqueueing a PR enqueues it and every unmerged layer below it, tests them together, and merges them atomically. After explicit user approval, comment/trunk mergeon the top PR to merge the whole stack, or on the highest layer you want landed to merge just the bottom part. Run this preflight on every layer being merged, not only the one you comment on./stacking-prscovers restack mechanics and the post-mergegh stack sync --prune.
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.
- today Changed be375304e5d1
- yesterday First seen · 162 lines · 165 tokens per session scan A 0c3afb4d6c37
merging-prs is a skill published in the GitHub repository PostHog/posthog-foss (713 stars, last pushed today), licensed MIT. It adds 165 tokens to every session and 3,025 once invoked, about $0.0008 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.
Other skills, from other repositories
systematic-debugging
Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.
next-cache-components-adoption
Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…
babysit-pr
Babysit a GitHub pull request after creation by continuously polling review comments, CI checks/workflow runs, and mergeability state until the PR is merged/closed or user help is required. Diagnose failures, retry likely flaky failures up to 3 times, auto-fix/push branch-related issues when appropriate, and keep…
imagegen
Generate or edit raster images when the task benefits from AI-created bitmap visuals such as photos, illustrations, textures, sprites, mockups, or transparent-background cutouts. Use when Codex should create a brand-new image, transform an existing image, or derive visual variants from references, and the output…
cpu-profile-analysis
Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…
next-cache-components-optimizer
Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…