What are stages 1, 2 and 3 in the index during a conflict?
AdvancedConceptConflicts, remotes, fetch, pull and push
Answer
Git keeps three entries for an unmerged path: stage 1 is the common ancestor, stage 2 is "ours", stage 3 is "theirs". You can read them directly and use git mergetool or git checkout-index.
git show :1:app.py # base
git show :2:app.py # ours
git show :3:app.py # theirs
git diff --base app.py
More on Conflicts, remotes, fetch, pull and push
What do conflict markers look like and how do you resolve them?BeginnerWhat is `merge.conflictStyle=zdiff3` and why use it?IntermediateHow do you quickly take one side's version for a conflicted file?IntermediateHow do you see what a merge conflict is about before resolving?IntermediateWhat is the difference between `git fetch` and `git pull`?BeginnerWhat is a remote and what does `origin` mean?Beginner