I want to know an exact algorithm (or near that) behind 'git merge'. The answers at least to these sub-questions will be helpful:
- How does git detect the context of a particular non-conflicting change?
- How does git find out that there is a conflict in these exact lines?
- Which things does git auto-merge?
- How does git perform when there is no common base for merging branches?
- How does git perform when there are multiple common bases for merging branches?
- What happens when I merge multiple branches at once?
- What is a difference between merge strategies?
But the description of a whole algorithm will be much better.
See Question&Answers more detail:os