Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Idea Intellij - compare between branches - contents are identical

I have a strange behavior in IDEA. While I'm comparing two different branches (one downloaded to local and one in repo), I get list of files with "differences".

The thing is, when I double click the file, it shows that files are identical and message Contents are identical

Is that really so? Is something cached in Idea? Or is it some bad behavior of SVN?

like image 753
xwhyz Avatar asked Jan 21 '15 13:01

xwhyz


2 Answers

I was bugged with the exact same problem, I just wanted to merge without being bothered by non-content changes.

I found out that (in IDEA 2016.2) you can compare differences between projects (folders) instead of versioning differences. It even gives a good graphical overview of additions and removals based on content instead of versioning data.

  1. Check out both branches
  2. Open the branch you want to merge to in IDEA
  3. Click the base folder you want to merge (probably the entire project folder) and press ctrl+D (Compare with...)

Now you get a far more complete window with all the changes and filtering options. You can even decide how intelliJ should compare (content, date,...)

like image 104
Pieter De Bie Avatar answered Oct 22 '22 07:10

Pieter De Bie


not only content but also the mode or other meta data can also be different,try this

git diff
like image 33
FF呀 Avatar answered Oct 22 '22 06:10

FF呀