mergiraf (OSS)

A syntax-aware git merge driver for a growing collection of programming languages and file formats. Canonical repo on codeberg.org/mergiraf/mergiraf (GitHub 404s — mirrors point back to Codeberg).

What it does

Plugs into git’s merge machinery (git merge, rebase, revert, cherry-pick) and resolves conflicts aware of the syntax trees in your files instead of line-by-line — so two sides touching different parts of the same structure merge cleanly. Teaches new languages declaratively. Errs toward keeping conflict markers on suspicious resolutions (mergiraf review to audit what it did); designed for interactive-speed merges.

Where it fits

The “prevention” end of the Diff tools landscape: structural diffs (diffyml/dyff/Difftastic) explain what changed, mergiraf stops conflicts from existing at all. Feeds Git recovery — rerere replays YOUR resolutions, mergiraf removes the need for a resolution in the first place.

Hands-on

(none yet — candidate for the homelab repos’ merge config; conflicts.md on mergiraf.org lists the conflict classes it solves)

Sources

  • Docs site capture: clippings/mergiraf-org.md
  • README (codeberg API): clippings/codeberg-org-mergiraf-mergiraf.md