git
conflict resolution
version control
duplicate question
git merge
Git conflict markers
Interview Questions practice on Codemia
Over 8,000 real interview questions from top companies, searchable by company and role.
Introduction
Git conflict markers appear when Git cannot merge two edits automatically and needs you to decide what the final file should contain. They are not part of Git history by themselves; they are temporary text inserted into your working tree so you can resolve the conflict manually.
What the Markers Mean
A typical conflict looks like this:
The sections mean:
- '
<<<<<<< HEADstarts the version from your current branch' - '
=======separates the two competing versions' - '
>>>>>>> feature-branchends the version from the branch being merged'
Sometimes you may also see a base section:
Related reading
- Git Confusion about merge algorithm, conflict format, and interplay with mergetools
- Git Corrupt loose object
- Git Could not resolve host github.com error while cloning remote repository in git
- Git, Create a branch from unstaged/uncommitted changes on master
- Git Create a branch from unstaged/uncommitted changes on master
- git 'credential-cache' is not a git command
- Git diff -w ignore whitespace only at start end of lines
- Git diff between current branch and master but not including unmerged master commits
.png&w=3840&q=75)
Free course
Beginner
7 lessons
2 hours
Tackling System Design Interview Problems
A short course that equips you with the skills to approach system design interviews methodically.
Start the free courseTrack what you have practised
A free account saves your progress, solutions and study plan across every problem on Codemia.
Interview Questions practice on Codemia
Over 8,000 real interview questions from top companies, searchable by company and role.