Three-Way Merge Conflict Resolution
Last updated 2026-05-15 · Acme Sync v1.2
TL;DR
Acme Sync uses the common ancestor snapshot to merge divergent file versions. Most conflicts resolve automatically. The rest surface in the CLI.
How it works
1 Snapshot the ancestor on every sync ▼
On every successful sync, Acme Sync records the SHA-256 hash of
each file into the local conflict store. This hash becomes the
ancestor snapshot — the agreed-upon baseline for both
machines.
2 Detect divergence on reconnect ▼
When a file changes on two machines while offline, both versions
are compared against the ancestor snapshot. If neither hash
matches the ancestor, the file is flagged as diverged.
3 Auto-resolve single-side changes ▼
If only one machine changed the file (one hash matches the
ancestor, the other doesn't), the changed version wins
automatically. No user action required.
4 Auto-merge non-overlapping edits ▼
If both machines changed the file but on different lines, Acme
Sync applies a standard diff3 merge. The result is committed and
the ancestor snapshot is updated. Binary files skip this step
entirely — they're copied whole.
5 Flag true conflicts for manual resolution ▼
When both machines edited the same line differently, Acme Sync
writes a conflict record to the conflict store and surfaces it in
the CLI with
acmesync conflicts list. The file is quarantined
until resolved.
Config snippets
# ~/.acmesync/config.toml — Local Dev [sync] debounce_ms = 150 auto_merge = true conflict_notify = "desktop" ancestor_ttl_days = 30 [storage] endpoint = "https://dev-bucket.acmesync.test" region = "us-east-1" [logging] level = "debug"
Glossary
ancestor snapshot
The file state (SHA-256 hash) recorded at the last successful
sync. Used as the common base when comparing diverged
versions.
three-way merge
A merge strategy that compares both changed versions against a
common base, enabling auto-resolution of non-overlapping
edits.
conflict store
An SQLite table on each device that records unresolved conflicts,
including both versions and the ancestor hash.
debounce window
The delay (default 150 ms) between a file-change event and the
sync trigger. Prevents excessive syncs during rapid edits.
presigned URL
A temporary S3 access URL generated per transfer. Valid for 15
minutes by default (configurable via
presign_ttl_s).
FAQ
Does Acme Sync handle binary files?▼
Binary files are copied whole — no line-level merge is attempted.
The most recently modified version wins. A warning is logged if
both sides changed.
What happens if I'm offline?▼
Changes queue locally in the conflict store and are synced
automatically on reconnect. No data is lost during offline
periods.
How long are ancestor snapshots kept?▼
30 days by default. Set
ancestor_ttl_days in your
config to override. Expired ancestors cause the next sync to treat
the file as new.