Resolving Merge Conflicts
See the current state of the merge/rebase. Check git history, and the conflicting files.
Find the primary sources for each conflict. Understand deeply why each change was made, and what the original intent was. Read the commit messages, check the PRs, check original issues/tickets.
Resolve each hunk. Preserve both intents where possible. Where incompatible, pick the one matching the merge's stated goal and note the trade-off. Do not invent new behavior. Always resolve; never
--abort.Discover the project's automated checks and run them — typically typecheck, then tests, then format/lint. Fix anything the merge broke.
Finish the merge/rebase. Stage everything and commit. If rebasing, continue the rebase process until all commits are rebased.
Combining with other skills
production-revert-discipline— if a conflict surfaces because two branches both touched a reverted feature, check whether the revert is still the right call before resolving in its favor.unmerged-work-census— a conflict is sometimes the first sign that a stale branch's content already landed elsewhere under different history; verify before assuming the conflicting branch is still the source of truth.tdd/diagnosing-bugs— step 4's test run is the gate; a test that breaks post-merge is a real regression to diagnose, not noise to silence.
Attribution
Adapted from mattpocock/skills (skills/engineering/resolving-merge-conflicts), MIT licensed, © Matt Pocock.