add-resolver

A procedure for adding support for a new file format or file extension to GitWand's conflict resolver. A conflict resolver decides how to combine competing file changes.

In plain words
What is it for?
Use it when supporting formats such as Prisma, TOML, Terraform, or lockfiles, or when adding a format-specific conflict-resolution strategy.
Why use it?
New formats require coordinated changes to the resolver, dispatcher, tests, and documentation. The procedure also helps choose a safe parsing method and confidence level.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/devlint/gitwand/add-resolver
Any agent
npx skills add devlint/GitWand --skill add-resolver
Clone the repo
git clone --depth 1 https://github.com/devlint/GitWand

Made for: Claude Code, Codex.

Per session 90 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,608 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found 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 $0.00090 $0.01608
Opus 5 $0.00045 $0.00804
Sonnet 5 $0.00018 $0.00322
Haiku 4.5 $0.00009 $0.00161

Measured 2d ago against content hash 8b97ba96657a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

add-resolver scanned grade A with 1 finding 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 2d 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.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

browsers — no Node.js imports (`fs`, `path`, `child_process`). If no
.claude/skills/add-resolver/SKILL.md · 211 lines

How it starts

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

Skill: add-resolver

Guide the agent through adding a format-specific resolver to packages/core end to end — file creation, dispatcher wiring, tests, and docs — without missing any of the four required touch points.


Step 1 — Qualify the need

Answer these before writing any code:

  1. Format / extension? (e.g. .prisma, composer.lock, .tf, .toml)
  2. Is it a lockfile? If yes → confidence is 0.95 by convention. Lockfile conflicts are almost always trivially re-generable, so high confidence is appropriate.
  3. Resolution strategy? Examples:
    • Structured config (key = value) → merge non-conflicting keys
    • Lockfile → accept one side; file is regenerable
    • Source code → be conservative, 0.70–0.80 max
  4. Browser-compatible parsing available? packages/core must run in browsers — no Node.js imports (fs, path, child_process). If no parser lib is available, write a pure string-manipulation parser.

Confidence score guidelines:

File type Score
Lockfile 0.95
Structured config (JSON, YAML, TOML, dotenv) 0.850.90
Source code 0.700.80
Never exceed 0.95 unless perfectly deterministic

Step 2 — Create the resolver file

Create packages/core/src/resolvers/<format>.ts. Follow this exact shape, which mirrors all existing resolvers in the directory:

/**
 * GitWand — <FORMAT> resolver
 *
 * Strategy: [describe the resolution strategy precisely]
 *
 * Handled cases:
 *  - [case 1]
 *  - [case 2]
 *  - [non-resolvable case → return null]
 */

// ✅ Allowed: pure string manipulation, parsing, algorithms
// ❌ FORBIDDEN: import * as fs from 'fs' / import * as path from 'path'

export interface ResolveResult {
  /** Resolved lines, or null if not resolvable */
  lines: string[] | null;
  /** Human-readable description of what was done (or why it failed) */
  reason: string;
}

/**
 * Attempts to resolve a <format> conflict.
 * Confidence: 0.XX — [justify the score here]
 */
export function tryResolve<Format>Conflict(
  baseLines: string[],
  oursLines: string[],
  theirsLines: string[],
): ResolveResult {
  // ... resolution logic ...

  return { lines: null, reason: "Non-resolvable: [reason]." };
}

Read the full file on GitHub · 211 lines

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. 2d ago First seen · 211 lines · 90 tokens per session scan A 8b97ba96657a

Subscribe to this mod's changes

add-resolver is a skill published in the GitHub repository devlint/GitWand (167 stars, last pushed 4d ago), licensed MIT. It adds 90 tokens to every session and 1,608 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

hunk-extensions

Maps the hunkdiff/extension authoring surface for Hunk, the terminal diff viewer — hiding or reordering reviewed files, docked panes, alternate file views, commands and key bindings, dialogs, workspace writes, themes, syntax languages, VCS backends, lifecycle events. Use when writing, debugging, or installing a Hunk…

modem-dev/hunk · 105 tokens

hunk-launch-video

Produces Hunk videos by driving the real TUI headlessly in a PTY, compositing captioned 1080p frames in Chromium, and encoding with ffmpeg. Use for feature demos, workflow explainers, announcements, launch videos, and full-release roundups.

modem-dev/hunk · 60 tokens

hunk-review

Interacts with live Hunk diff review sessions via CLI. Inspects review focus, navigates files, hunks, and exact lines, reloads session contents, adds inline review comments, and paints attention marks on character ranges. Use when the user has a Hunk session running or wants to review diffs interactively.

modem-dev/hunk · 69 tokens

hunk-release

Prepares, publishes, verifies, and curates Hunk releases. Use for release metadata, benchmarks, tags, publishing, release videos, backports, or recovery.

modem-dev/hunk · 38 tokens

mobile-app

像素级 iPhone 15 Pro 边框, 一屏 app 截图.

nexu-io/html-anything · 21 tokens

git-machete

Use whenever invoking the git machete CLI to organize branch chains, compute fork points, run stacked rebases/merges, or manage GitHub/GitLab PR/MR chains - especially in a repo that already has a .git/machete file. Lists which subcommands modify .git/machete, run rebase/merge, run hooks, or read stdin, so the agent…

VirtusLab/git-machete · 165 tokens