0

In Eclipse I compare 2 branches – the current branch and the release branch. There is no difference between the current branch and the release branch for the file build.gradle, nevertheless synchronize shows the red flag. Why? And how to fix this?

The command

git diff current release build.gradle

shows no difference

enter image description here

Alex
  • 7,007
  • 18
  • 69
  • 114
  • Can you show the console output of running a git diff for that file? If you don't know how, it would look something like `git diff branch1 branch2 build.gradle`. This will tell you if there are really differences or if it is just an error on the extension of Eclipse. – Drubio Jan 04 '19 at 20:51
  • Are you really sure there are no whitespace or encoding changes? – howlger Jan 04 '19 at 22:43
  • Drubio, please see the updated description – Alex Jan 07 '19 at 20:39

1 Answers1

0

I had the same problem. After doing some research I found this helpful answer.

While in the appropriate directory, I executed git rm -r --cached . and reverted back the identified file without committing it. After that, I did the team synchronization in Eclipse and it wasn't showing any differences anymore.

sloppypasta
  • 1,068
  • 9
  • 15
kiranramanna
  • 115
  • 1
  • 9