Questions about resolving merge conflicts in Git.
Questions tagged [git-merge-conflict]
518 questions
1
vote
1 answer
Unresolvable git merge conflict
I have worked on this problem for three days and I can't find a solution for this merge conflict. Can somebody please help me out here?

thgie
- 2,367
- 1
- 18
- 28
1
vote
1 answer
Bulk resolve remaining merge conflicts as 'ours' for deleted files
Is there a way to say 'for all remaining merge conflicts', select 'ours' as the merge conflict resolution?
In my case 'ours' is also a deletion, not an edit.
I'm using Git Extensions, with a little bit of command line work.
When I do a merge, I go…

Sean Holmesby
- 2,135
- 3
- 23
- 34
1
vote
2 answers
git pull origin branch wants a merge on clean current master branch
I'm on a my master branch which is a perfect clean (but git presents it that it is ahead of origin/master by 14 commits). When I try to pull a different branch from origin (Eagle) git wants me to merge a few files.
This is not what I expect: When…

dr jerry
- 9,768
- 24
- 79
- 122
1
vote
2 answers
How to rollback a single conflict resolution during git rebase
In the middle of a long rebase I stumbled upon a following situation.
I got conflicts in several files and started resolving them one by one and marking resolutions with git add. After all was done I realized I made a mistake in one of resolutions.…

Dmitry Vyal
- 2,347
- 2
- 24
- 24
1
vote
1 answer
Why can a changeless rebase fail?
I have a git repo with quite some history by now.
I was trying to do some changes on early commits and found weird conflicts.
I found out that if I do a git rebase COMMIT^ and choose one of the early ones, but then on the list I don't touch…

Arkaitz Jimenez
- 22,500
- 11
- 75
- 105
1
vote
1 answer
How to do Git conflict resolution using a separate resolution branch?
I have following branches on my local:
master
branch-a
branch-b
branch-c
dev
I created PR (Pull Request) for branch-a (PRA-1), branch-b (PRB-1), branch-c (PRC-1). My colleagues finished reviewing my code. Since I know that branch-a, branch-b,…

Yamin Noor
- 53
- 4
1
vote
1 answer
Can anyone help me to understand three window in Meld diff tool
While using Meld I am seeing three vertical side
On left Test.txt.LOCAL.10512.txt
In middle Test.txt
On Right Test.txt.REMOTE.10512.txt
Can anyone help me to understand these three window. and which one should i consider as final merged file ? I am…

Manish Kumar
- 10,214
- 25
- 77
- 147
1
vote
0 answers
Why does Git sometimes list conflicts with 'ours/theirs' instead of 'HEAD/branch'?
I undid an attempted merge conflict using git checkout -m <> and was surprised to see the conflicts listed as:
<<<<<<< ours
-------
>>>>>>> theirs
instead of:
<<<<<<< HEAD
-------
>>>>>>> branch
Is there a global setting that controls…

Steve Chambers
- 37,270
- 24
- 156
- 208
0
votes
0 answers
Github: Why revising a csv file in a branch results in a conflicting merge?
I'm sorry for this very basic question but I can't understand why revising a csv file that I pulled from the master would create a conflict in my pull request.
What happened is, I have a collaborative repo with main branch which contains a file.csv.…

user496181
- 141
- 7
0
votes
0 answers
VS Code Merge Editor doesn't get populated
I tried to git pull but couldn't because I got conflicts. There is a button on the file saying "Resolve in Merge Editor".
When I click it, Merge Editor opens (the three-window one) but it never goes beyond loading state.
I updated VS code, toggled…

Eli K
- 21
- 2
0
votes
0 answers
git merge conflicts due to reverting: what strategies can be used to avoid such conflicts?
this images describes the issue we were facing
branch k had merged b2 into itself, which was a mistake, we actually did not want any b2 related changes going into k.
then k merged itself into b1, which brought in the b2 changes as well, which we do…

Cui Pengfei 崔鹏飞
- 8,017
- 6
- 46
- 87
0
votes
1 answer
"git rebase master" is finding conflicts in files only in my branch and not master
Here is my problem:
I branched off master, naming the branch other_branch.
I worked a long time on my branch, rebasing daily
we tabled the project for a month
somewhere during that time, it appears someone else directly manipulated git history on…

jaydel
- 14,389
- 14
- 62
- 98
0
votes
1 answer
Git Merge takes all files into the PR after fixing conflicts
I have been looking for this, but not able to find a concrete answer which works.
Say I am working on my branch - branchA and I have a Pull request (PR) ongoing with it.
Some updates happen on the master and I need to merge those changes
Scenario 1…

Nitron_707
- 307
- 4
- 10
0
votes
0 answers
Moving a line is not atomic in git
Imagine the following git flow:
R1 refactoring #1
/ \
/ \
---A------M1---M2--- master
\ /
\ /
R2----- refactoring #2
The code in the A-snapshot looks…

ESkri
- 1,461
- 1
- 1
- 8
0
votes
1 answer
Git: Is there a merge strategy that will prevent me from having to resolve conflicts manually in this fairly simple case?
Scenario. I have a file like this in my main git branch:
A
B
One developer on branch A turns that into:
a
B
Another developer on branch B turns that into:
A
b
I want the result to be:
a
b
I know the A developer will not touch the B line and vice…

gctwnl
- 217
- 1
- 8