Loading tutorials
git log. It explains how Git decides what a merge should produce, which is the basis for understanding why conflicts happen later.3 min readgit log. It covers the two shapes a successful merge can take, and how to choose between them.2 min readgit merge. You should also know why a merge can stop with a conflict, which the previous chapter covered. Here you learn to read what Git writes into a conflicted file.2 min readgit diff. It uses the config.txt conflict from the previous chapters. When git merge feature stops, Git has not finished. It has put the repository into a merge state, and you can examine that state with three commands befo2 min readgit status output. You should also know what a conflict looks like in a file. Here you will learn how to abandon an unfinished merge and get back to a clean state.3 min readgit merge, read conflict markers, and edit a conflicted file by hand. Here you learn how to confirm a resolution is correct before and after you commit it.3 min readgit add. Sometimes the right fix for a conflict is to keep one version unchanged. Git has commands for that, and the words "ours" and "theirs" appear in several places with different meanings.3 min readgit status during a merge, and finish a merge with git add and git commit. It covers git mergetool, which opens a visual tool for each conflicted file.2 min readgit status, and finish a merge with git add and git commit. Some conflicts have no markers to edit. Git stops because it cannot decide whether a file should exist, where it lives, or how to combine its bytes.2 min read