Getting started
Committing
Browsing the history
Undoing
Staging
Git diff
Syntax
Show differences in working branch
Show changes between two commits
Show differences for staged files
Compare branches
Show both staged and unstaged changes
Show differences for a specific file or directory
Viewing a word-diff for long lines
Show difference between two commits or branches
Show differences between current version and last version
Produce a diff compatible with patch command
Using meld to see all modifications in the working directory
Diff UTF-16 encoded text and binary plist files
Show changes between two branches
View a three-way merge including the common ancestor
Merging
Ignoring files and folders
Working with remotes
Submodules
Aliases
Rebasing
Configuration
Branching
rev-list
Squashing
Cherry picking
Recovering
git clean
.gitattributes
.mailmap
Different workflows
Pulling
Hooks
Cloning repositories
Stashing
Subtrees
Renaming
Pushing
Internals
git-tfs
Empty directories in git
git-svn
Archive
Rewriting history with filter-branc
Migrating to git
Show
Resolving merge conflicts
Bundles
Display commit history graphically with gitk
Bisecting to find faulty commits
Blaming
Git revisions syntax
Worktrees
Git remote
Git large file storage
git patch
git statistics
git send-email
git gui clients
reflog - restoring commits not shown in git log
TortoiseGit
External merge and diff tools
Update object name in reference
Git branch name on Bash Ubuntu
Git client-side hooks
Git rerer
Change git repository name
git tagging
tidying up your local and remote repository
diff tree
Contributors

View a three-way merge including the common ancestor

suggest change
git config --global merge.conflictstyle diff3

Sets the diff3 style as default: instead of the usual format in conflicted sections, showing the two files:

<<<<<<< HEAD
left
=======
right
>>>>>>> master

it will include an additional section containing the original text (coming form the common ancestor):

<<<<<<< HEAD
first
second
||||||| 
first
=======
last
>>>>>>> master

This format makes it easier to understand merge-conflict, ie. in this case locally second has been added, while remote changed first to last, resolving to:

last
second

The same resolution would have been much harder using the default:

<<<<<<< HEAD
first
second
=======
last
>>>>>>> master

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents