AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Resolve Merge Conflicts

skill-stealth-engine-skills-resolve-merge-conflicts · by stealth-engine

Resolve git merge/rebase conflicts non-destructively — preserving the intent of BOTH sides — and hand off to a human when a conflict can't be resolved safely. Use when a branch or PR has conflicts with its base ('this branch has conflicts that must be resolved', GitHub mergeable=CONFLICTING / mergeStateStatus=DIRTY), when a rebase / merge / cherry-pick / stash / revert stops with conflict markers…

No reviews yet
0 installs
31 views
0.0% view→install

Install

$ agentstack add skill-stealth-engine-skills-resolve-merge-conflicts

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-stealth-engine-skills-resolve-merge-conflicts)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
2mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Resolve Merge Conflicts? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Resolve merge conflicts (non-destructively)

Resolve git conflicts so that both sides' intent survives, verify the result, and stop and ask a human the moment a safe resolution isn't obvious. The git mechanics are the easy part; the danger is silently dropping someone's work — a blind "take theirs," a clean-looking textual merge that's logically broken, or a force-push over a teammate's commits.

Command recipes live in [reference/playbook.md](./reference/playbook.md) (load on demand). This body is the decision rules.

First: rebase or merge?

You update a feature/PR branch against its base one of two ways. Either is fine — pick by context, not dogma:

| | git rebase origin/main | git merge origin/main | | --- | --- | --- | | History | linear (replays your commits) | adds a merge commit | | Conflicts | may re-hit the same conflict per replayed commit (turn on rerere) | resolve once | | Push after | --force-with-lease (rewrites your branch) | normal push | | Best for | your own unshared PR branch | a branch others also commit to |

In a squash-merge repo (see [git-trunk-branch-and-pr-automation](../git-trunk-branch-and-pr-automation/SKILL.md)) the feature branch's history is flattened at merge anyway, so a merge commit on the branch is harmless — when a rebase keeps re-conflicting, merge instead and resolve once. Never rebase a branch other people are actively committing to.

The non-negotiable safety rules

  1. Never blind-resolve a whole side. -X ours / -X theirs (strategy options)

and git checkout --ours/--theirs take one side wholesale and throw the other away silently. They're only correct for files you will regenerate (e.g. lockfiles) or a file that genuinely should be one side entirely — never as a "make the markers go away" shortcut.

  1. Resolve hunk-by-hunk, preserving both intents. A conflict means both sides

changed the same region. The correct result is usually neither side verbatim but a combination. Turn on diff3/zdiff3 so you can see the common ancestor and reason about what each side changed from (recipe in the playbook).

  1. Know the rebase ours/theirs inversion. During git merge, ours=your branch,

theirs=incoming. During git rebase, it's flipped: ours=the branch you're replaying onto (e.g. main), theirs=your commits. Acting on the wrong one discards exactly the work you meant to keep.

  1. Keep the escape hatch ready. git merge --abort / git rebase --abort /

git cherry-pick --abort returns you to a clean pre-conflict state. If unsure, abort and reassess rather than push a half-resolved tree. git reflog + ORIG_HEAD recover from a bad finish.

  1. Force-push only --force-with-lease, only your own PR branch. Plain

--force clobbers teammate commits pushed since your last fetch; --with-lease refuses if the remote moved.

  1. Never commit conflict markers. Run git diff --check and

git diff --cached --check (staged markers won't show in the unstaged diff after git add), plus a grep for `,

  • GitHub PR mergeability fields (mergeable, mergeStateStatus = DIRTY on

conflict):

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.