GitHub
GitHub logoGitHub · Feature trail

Git Merge Strategy Optimization

2 posts · Dec 2015 – Jul 2023

What this trail covers

This feature thread tracks the evolution of Git merge strategies and their implementation in production systems. Initially, GitHub used a custom shell script workaround based on `git-merge-resolve` for bare repositories, which had performance and complexity drawbacks. This post details the transition to using `merge-ort` for both merges and rebases, leveraging `git-replay` for rebases. The new implementation significantly improves performance and correctness, addressing issues with merge base selection and eliminating the need for a working directory. Future work includes applying `merge-ort` to squashing and reverting operations.

All GitHub trails