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 skills add ericboehs/claude-plugins --skill merge-and-cleanupgit clone --depth 1 https://github.com/ericboehs/claude-pluginsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/ericboehs/claude-plugins/merge-and-cleanup)<a href="https://agentmods.dev/skills/ericboehs/claude-plugins/merge-and-cleanup"><img src="https://agentmods.dev/badge/skills/ericboehs/claude-plugins/merge-and-cleanup/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/ericboehs/claude-plugins/merge-and-cleanup"><img src="https://agentmods.dev/badge/skills/ericboehs/claude-plugins/merge-and-cleanup.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00057 | $0.01116 |
| Opus 5.5 | $0.00023 | $0.00446 |
| Sonnet 5.5 | $0.00011 | $0.00223 |
| Haiku 4.5 | $0.00006 | $0.00112 |
Grade A, and why
merge-and-cleanup 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 2mo 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.
How it starts
The opening of the file, as written. The whole thing — 118 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Merge and Cleanup
Merge the current branch's PR via squash merge, delete the remote branch, switch to main, pull, and clean up the worktree if applicable.
Workflow
Step 1: Detect context
Run these commands to understand the current state:
# Get current branch
BRANCH=$(git branch --show-current)
echo "Branch: $BRANCH"
# Check if on main/master
DEFAULT_BRANCH=$(git remote show origin | sed -n 's/.*HEAD branch: //p')
if [ -z "$DEFAULT_BRANCH" ]; then
DEFAULT_BRANCH=$(git symbolic-ref refs/remotes/origin/HEAD 2>/dev/null | sed 's|refs/remotes/origin/||')
fi
echo "Default branch: $DEFAULT_BRANCH"
# Check for uncommitted changes
git status --porcelain
# Check if in a worktree
GIT_DIR=$(git rev-parse --git-dir)
GIT_COMMON_DIR=$(git rev-parse --git-common-dir)
echo "git-dir: $GIT_DIR"
echo "git-common-dir: $GIT_COMMON_DIR"
- If
DEFAULT_BRANCHis empty, report "Could not determine the default branch — check that theoriginremote is configured" and stop. - If
BRANCHequalsDEFAULT_BRANCH(main/master), report "Already on the default branch, nothing to merge" and stop. - If
git status --porcelainhas output, warn the user about uncommitted changes and ask whether to proceed. - If
GIT_DIR!=GIT_COMMON_DIR, we're in a worktree. Note the current worktree path (pwd) and the main repo path (parent ofGIT_COMMON_DIR).
Step 2: Find and merge the PR
# Look up PR for this branch
gh pr view --json state,number,title,mergeStateStatus,statusCheckRollup
- If no PR exists, tell the user and suggest creating one with
gh pr create. Stop. - If the PR state is not
OPEN, tell the user the PR is already closed/merged. Stop. - If
mergeStateStatusisBLOCKEDor status checks are failing, warn the user and ask whether to proceed anyway. - If everything looks good, merge:
gh pr merge --squash --delete-branch
If the merge fails, report the error and stop. Note: when in a worktree, --delete-branch may warn about failing to delete the local branch (since it's checked out). This is expected — the local branch will be cleaned up when the worktree is removed in Step 4. Only treat it as a failure if the merge itself fails.
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.
- 2mo ago First seen · 118 lines · 57 tokens per session scan A 2c37c132b1f4
merge-and-cleanup is a skill published in the GitHub repository ericboehs/claude-plugins (2 stars, last pushed 2mo ago), licensed MIT. It adds 57 tokens to every session and 1,116 once invoked, about $0.0002 per session on Opus 5.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.
merge-and-cleanup compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| merge-and-cleanupericboehs/claude-plugins | Skill | 2 | 2mo ago | MIT | A | 57 | Claude Code |
| release-announcementpaperclipai/paperclip | Skill | 112k | today | MIT | A | 42 | Claude Code, Codex |
| releasethedotmack/claude-mem | Skill | 114k | today | Apache-2.0 | A | 13 | Claude Code |
| release-notesphuryn/pm-skills | Skill | 28k | 9d ago | MIT | A | 57 | Claude Code |
| multi-agent-release-managerchromium/chromium | Skill | 25k | today | BSD-3-Clause | A | 27 | Claude Code, Codex |
| pack-submitaeonfun/aeon | Skill | 789 | 2d ago | MIT | A | 27 | Claude Code, Codex |
| updater_guidesiddsachar/row-bot | Skill | 1.7k | today | Apache-2.0 | A | 22 | Claude Code, Codex |