0

I have a couple of conflicted files and I don't have access to source branches (these files are detached from the repository. There isn't any .git folder and I don't have original versions). There are some conflicts marked by git-merge:

<<<<<<< HEAD
    sizeof(.......bla bla
||||||| merged common ancestors
    sizeof(.......ble ble
=======
    sizeof(.......blu blu
>>>>>>> refs/heads/TAGNAME

Is there a way to see such file in human-readable mode, i.e. parse a single file with marked conflicts and split it to a side-by-side view? I suppose Meld cannot do it, and KDiff3 seems to be unable to do the trick too.

git merge (tool) says that this isn't a Git repository.

git diff --no-index requires two parameters (two files to compare), and as mentioned before I don't have the input files.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
ardabro
  • 1,907
  • 16
  • 31
  • Any major IDE can do this, e.g. IntelliJ or Eclipse if you are working with Java. – Tim Biegeleisen Dec 06 '17 at 09:18
  • How about sourceTree? – David Wei Dec 06 '17 at 09:19
  • 1
    I'm curious, why did you put the [tag:kdiff3] tag on your question, when that's a tool designed to do exactly what you're asking? – David Z Dec 06 '17 at 09:20
  • This question is off-topic. Please check what topics you can ask here ([help/on-topic]). – evolutionxbox Dec 06 '17 at 09:38
  • David Z: So tell me please how to achieve it with kdiff3. The only effects I observe is one panel fillend and empty second panel or the information that files are identical when I'm trying to open the same file twice - on both panels. – ardabro Dec 06 '17 at 09:54

2 Answers2

0

Use P4Merge to visualize the differences. You can set it up as the default tool used by Git-Diff and Git-Merge. Here is the effect.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
haolee
  • 892
  • 9
  • 19
0

Meld can indeed handle visualising conflicts

Source: Resolving merge conflicts

Enter image description here

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Edmund Dipple
  • 2,244
  • 17
  • 12