merge-agent.tmp

merge-agent.tmp is a skill for Claude Code, Codex from EZotoff/ez-omo-config. It costs 0 tokens per session (1,981 once invoked), scanned A, a copy of merge-agent, MIT.

A guarded Git workflow for merging a branch from a separate worktree into the main branch. It checks the local state, prevents concurrent merges, and can roll back failed steps.

In plain words
What is it for?
Use it to rebase a worktree branch, merge it through the main worktree, resolve merge problems, and remove the worktree safely.
Why use it?
It reduces the risk of merging from the wrong directory, leaving locks behind, or losing track of cleanup after a conflict or failure.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: positional $N argument; mentions OpenCode.

Good fit Use it to rebase a worktree branch, merge it through the main worktree, resolve merge problems, and remove the worktree safely.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ezotoff/ez-omo-config/merge-agent.tmp
Install

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.

Any agent
npx skills add EZotoff/ez-omo-config --skill merge-agent.tmp
Clone the repo
git clone --depth 1 https://github.com/EZotoff/ez-omo-config

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for merge-agent.tmp

README.md
[![agentmods](https://agentmods.dev/badge/skills/ezotoff/ez-omo-config/merge-agent.tmp/github.svg)](https://agentmods.dev/skills/ezotoff/ez-omo-config/merge-agent.tmp)
Your own site
<a href="https://agentmods.dev/skills/ezotoff/ez-omo-config/merge-agent.tmp"><img src="https://agentmods.dev/badge/skills/ezotoff/ez-omo-config/merge-agent.tmp/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.

agentmods 80×15 button for merge-agent.tmp

Your own site · 80×15
<a href="https://agentmods.dev/skills/ezotoff/ez-omo-config/merge-agent.tmp"><img src="https://agentmods.dev/badge/skills/ezotoff/ez-omo-config/merge-agent.tmp.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,981 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 100% copy Near-identical to another mod in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.01981
Opus 5.5 $0.00000 $0.00792
Sonnet 5.5 $0.00000 $0.00396
Haiku 4.5 $0.00000 $0.00198

Measured 11d ago against content hash 6bbf5d3d6e23, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

merge-agent.tmp 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 11d 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.

Origin

This is a copy

100% identical to merge-agent — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

skills/merge-agent/merge-agent.tmp/SKILL.md · 302 lines

How it starts

The opening of the file, as written. The whole thing — 302 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/merge-worktree

Safely merge a worktree branch into main with strict local state tracking, lock discipline, and deterministic rollback.

  • Name: merge-agent
  • Description: Safely merge worktree branches into main with state tracking and conflict resolution
  • Triggers: /merge-worktree, merge branch, integrate worktree

Usage

/merge-worktree <branch>
/merge-worktree --branch=<branch>

Optional runtime context:

  • project-id: Used for state path resolution under ~/.local/share/opencode/worktree-state/<project-id>/
  • session-id: Used for merge lock ownership (lockedBy)

Overview

This skill performs a guarded local-only merge flow:

  1. Pre-Merge Validation — ensure we are in a feature worktree and clean
  2. Merge Lock Acquisition — serialize merges via merge.lock
  3. Rebase Before Merge — rebase branch onto origin/main
  4. Merge Execution — merge from the main worktree, never from feature worktree context
  5. Post-Merge Cleanup — finalize state, release resources, remove worktree
  6. Rollback — deterministic failure handling for each failure mode

Pre-Merge Validation

1) Verify we are in a worktree (NOT primary main checkout)

Run:

git rev-parse --git-common-dir

Rules:

  • If result equals .git (or resolves to primary checkout root), STOP.
  • Merge execution must originate from a feature worktree session, but actual merge command runs in the main worktree path using git -C.

2) Verify working tree is clean

Run:

git status --porcelain

Rules:

  • Any output means uncommitted changes exist.
  • STOP until all changes are committed.

3) Load branch state

Read state file:

~/.local/share/opencode/worktree-state/<project-id>/worktrees/<branch>.json

Validate:

  • file exists
  • branch matches target branch
  • status is eligible (ready or merging recovery state)
  • worktreePath exists

If validation fails: mark state failed if possible and stop.

Read the full file on GitHub · 302 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

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.

  1. 11d ago First seen · 302 lines · 0 tokens per session scan A 6bbf5d3d6e23

Subscribe to this mod's changes

merge-agent.tmp is a skill published in the GitHub repository EZotoff/ez-omo-config (6 stars, last pushed 2d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,981 tokens. A static security scan graded it A with 0 findings. It is 100% identical to merge-agent, differing in 0 lines, and is treated as a copy.