resolve-conflicts
Skill10 starsChanged 56 days agoMITView on GitHub
Resolve Git merge or rebase conflicts by both sides' intent; verify the result.
- Deletes or force-pushes
- Commits and pushes
8 other projects use a version of this.
Adopted by
Most recently taken up by
- domengabrovsek/agent-configtheir own version, first seen Oct 2, 2026
- mthines/agent-skillstheir own version, first seen Sep 25, 2026
- nielsmadan/skillstheir own version, first seen Sep 5, 2026
- fuadnafiz98/skillstheir own version, first seen Aug 3, 2026
- loremaster-ai/loremastertheir own version, first seen Jul 21, 2026
- Pradnyeshp/Claude-Skillstheir own version, first seen Jul 6, 2026
Other versions8 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 8
- domengabrovsek/agent-config★ 17same name
- mthines/agent-skills★ 13same name
- loremaster-ai/loremaster★ 4same name
- ralphkrauss/agent-orchestrator★ 4same name
- Pradnyeshp/Claude-Skills★ 2same name
- nielsmadan/skills★ 1same name
- ForeverAProgrammer/claude-devflow★ 0same name
- fuadnafiz98/skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository101 other files it gives its agents.
- AGENTS.mdAGENTS.md
- dot_agents/AGENTS.mdAGENTS.md
- skills/agent-project/templates/AGENTS.mdAGENTS.md
- skills/repository-docs/references/agents.mdAGENTS.md
- chezmoiSkill
- dot-developmentSkill
- dot-releaseSkill
- dot-skillsSkill
- dot-verifySkill
- acliSkill
- agent-evaluationSkill
- agent-frameworksSkill
- agent-harnessesSkill
- agent-loopsSkill
- agent-projectSkill
- agent-protocolsSkill
- agent-usageSkill
- agySkill
- airflowSkill
- ai-security-assessmentSkill
- api-clientSkill
- ast-grepSkill
- auth-statusSkill
- awsSkill
- benchmarkSkill
- bfSkill
- chrome-devtoolsSkill
- cli-developmentSkill
- clipboardSkill
- cloud-runSkill
- code-securitySkill
- colabSkill
- containerizeSkill
- course-developmentSkill
- databricksSkill
- data-migrationSkill
- delegate-tasksSkill
- diagrams-as-codeSkill
- dockerSkill
- documentation-siteSkill
- dot-cliSkill
- dprintSkill
- draft-mailSkill
- duckdbSkill
- fact-checkSkill
- fmind-visualsSkill
- full-reviewSkill
- gcloudSkill
- ghSkill
- git-deliverySkill
- github-actionsSkill
- github-issuesSkill
- github-pull-requestSkill
- github-repositorySkill
- git-worktreeSkill
- google-developerSkill
- gwsSkill
- handoffSkill
- hfSkill
- implementation-planSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
2 rules. 0 are common, 1 is distinctive, and 1 is very specific to this project.
0
Common
Most of the 8 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 40
Prove it: Run the repository's owning gate (e.g.
- Distinctive: line 49
Stop when unsure: if intent cannot be recovered from history, ask the user for the decision.
“Common” is measured: kept by at least 6 in 10 of the 8 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Resolve Conflicts
Finish a stopped git merge or git rebase by understanding what each side meant, not by picking a side. If the operation targets the wrong base or cannot safely continue, preserve existing resolutions and report the problem before an authorized abort; aborting can discard conflict-resolution work. Never "take ours" unless history shows the incoming change is obsolete.
Workflow
- Map the state: identify which operation stopped, the current and incoming commits, and every conflicted file before editing.
git status --short # UU both modified; AU, UA, DU, UD: added or deleted on one side git diff --name-only --diff-filter=U git rev-parse -q --verify MERGE_HEAD # merge only git rev-parse -q --verify REBASE_HEAD # rebase only - Read both intents: inspect the available index stages and operation-specific history before touching a hunk. Add/delete conflicts legitimately lack one or more stages; a missing stage is evidence, not a reason to restore a deleted file. During a rebase,
oursis the branch being rebased onto andtheirsis the commit being replayed.git show :1:<file> # common ancestor git show :2:<file> # ours; rebase target during a rebase git show :3:<file> # theirs; replayed commit during a rebase git log --merge --oneline -- <file> # both sides' commits touching the file; Git 2.45+ also covers rebase, cherry-pick, revert git show REBASE_HEAD -- <file> # rebase: the commit currently being replayed - Resolve semantically: write the code that satisfies both intents (renamed function plus new caller, both new tests, merged config keys). When intents are incompatible, keep the one matching the merge's goal and record the trade-off in the commit body. Do not invent new behavior, and remove every
<<<<<<<,=======,>>>>>>>marker. - Continue: stage the resolved files and resume; repeat per commit during a rebase.
git add <file>... git rebase --continue # or: git merge --continue - Prove it: Run the repository's owning gate (e.g.
mise run all); when the tree carries unrelated changes, apply the dirty-tree rule. Fix what the merge broke before pushing. - Push only when already authorized: a rewritten private branch may need
git push --force-with-lease; resolving conflicts alone does not authorize that history update, and never force-push a shared branch (main, or one others build on), merge into it instead.
Gotchas
- Show the ancestor:
git config merge.conflictStyle zdiff3puts the base version inside the markers so both sides' edits are visible. - Regenerate lockfiles and generated code: resolve source manifests first, use either generated side only as a starting point, then run
uv lockor the owning generator and review the regenerated diff. - Investigate one-sided deletions first:
DUorUDmeans one side removed the file; find out why before restoring it. - Enable rerere from the rebase start: the same hunk can conflict on several commits. Start the rebase with
git -c rerere.enabled=true rebase <base>and repeat the-con every--continue; enabling it only at--continuedoes not record the conflict already stopped on. Either form creates$(git rev-parse --git-path rr-cache), which keeps rerere active whilererere.enabledis unset, so remove that directory afterwards if it did not exist before. Persisting rerere throughgit configor that directory changes repository configuration and needs consent. - Stop when unsure: if intent cannot be recovered from history, ask the user for the decision; contacting the author requires authorization.
Documentation
- git merge · git rebase · git rerere
- Adapted from mattpocock/skills resolving-merge-conflicts (removed upstream in
daa01d8). - Companion skills: git-add-commit-push (commit and push), repository-history (why a change exists), mise (the gate).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

