Merge tool

Most conflicts are not interesting

Whitespace moved. One side changed and the other did not. The same edit arrived twice. GitComet resolves those the moment the file opens, and leaves you the ones that actually need a decision.

GitComet three-way merge resolver showing base, local, and remote columns with auto-resolved chunks

Resolution

Assisted, not automatic

When a conflicted file opens, GitComet applies a small set of rules to it. Each one only fires where the outcome is unambiguous, so the resolutions it makes are the ones you would have made yourself.

Identical sides

Both branches made the same change. There is nothing to choose between.

Only one side changed

One branch still matches the common ancestor and the other moved. The change is the answer, whichever side it came from.

Split into smaller chunks

A large conflict is broken into line-level pieces, and the pieces that no longer conflict are merged.

Everything else stays open and waiting for you.

Controls

Then you decide the rest

Three columns and an output

Base, local, and remote side by side, with the resolved result in an editable pane below. The rows line up, so you are comparing the same line across all three. A two-way view is one toggle away.

Pick a side, or both

A, B, C, and D take the base, ours, theirs, or both. Apply one choice to every remaining conflict at once, or undo a single decision with the session's own undo history.

Jump to what is unresolved

Shift+F2 and Shift+F3 skip past everything already settled. An overview column down the side shows where the remaining work is.

Align lines by hand

When the automatic alignment misreads a large move, select the lines that belong together and press Ctrl+Y — the same manual diff help KDiff3 offers. Clear all alignments with Ctrl+Shift+Y.

Split and join conflicts

Break one conflict into two where the tool grouped unrelated edits together, or join a conflict with its neighbour when they should be decided as one.

Not just text

Binary conflicts, keep-or-delete conflicts, and add/add conflicts with no common ancestor each get a view built for that decision rather than a wall of markers.

Setup

Drop-in for KDiff3 and Meld

One command registers GitComet as both your git mergetool and your git difftool. It writes a headless entry and a graphical entry, and sets guiDefault to auto, so Git picks the window when you have a display and the algorithm when you do not.

Configure Git

gitcomet setup

Add --local to configure only the current repository, or --dry-run to print the commands without applying them. Setup is idempotent, and it backs up any values it replaces.

Undo it

gitcomet uninstall

Uninstall restores your previous configuration, and leaves any setting you changed yourself alone.

Existing scripts keep working

GitComet accepts the KDiff3 and Meld argument forms — the --L1, --L2, and --L3 label flags, -o and --output, and positional paths.

Works without a display

gitcomet mergetool --auto resolves what it safely can and exits 0 when the file came out clean, 1 when markers remain. Usable from a script or a CI job.

Configurable to match your team

Conflict markers in merge, diff3, or zdiff3 style, Myers or histogram diffing, and a marker size of your choosing.

Correctness

A merge tool has to be right

Assisted resolution is only worth having if you can trust it. GitComet's merge engine is tested against 212 distinct merge cases, largely ported from libgit2's own merge test corpus.

Parity with Git

Continuous integration runs GitComet's merge output against Git's own merge test suites on every change.

End-to-end tool tests

A separate job drives GitComet through real git mergetool and git difftool invocations.

Regression corpus

The fixture suite runs on every pull request, so a resolution that was correct yesterday stays correct.

FAQ

Questions about using it as your merge tool

Can I use GitComet as my git mergetool?

Yes. Running gitcomet setup registers GitComet as both a headless and a GUI mergetool and difftool, with guiDefault set to auto so Git picks the graphical version when a display is available and the headless one otherwise. The command is idempotent and gitcomet uninstall restores your previous configuration.

Is GitComet a drop-in replacement for KDiff3 or Meld?

Yes. GitComet accepts the KDiff3 and Meld invocation forms, including the L1, L2, and L3 label flags, the output flags, and positional arguments, so existing scripts and Git configurations keep working.

Does the merge tool resolve conflicts automatically?

GitComet applies a small set of conservative rules when a conflicted file opens — both sides identical, a change on only one side relative to the common ancestor, and whitespace-only differences — and it can also split a large conflict into smaller line-level chunks that then merge cleanly. Anything it is not confident about is left open for you to decide.

Can GitComet merge without a graphical session?

Yes. The mergetool command has an --auto mode that resolves what it can and exits with status 0 when the file is fully resolved and 1 when conflict markers remain, which makes it usable in scripts and CI.