Why IntelliJ IDEA does not support properly diff for git merges?
I use IntelliJ IDEA since version 12., but none of it up to version 2016 properly support diff for git merge commits - it's look like IDEA check differences only for merge commit, ignoring differences between merge parents
For example in cmd/bash:
$ git log
commit 647a525105da38554114705308e7ea02f6caa821
Merge: ac4a51e 795923c
...
$ git diff 647a525105da38554114705308e7ea02f6caa821
(nothing at all)
$ git diff ac4a51e 795923c
(about 47 files modified/added/deleted)
For this example IntelliJ IDEA shows there is nothing to show in diff list (Checked for version 12, 13, 14, 15, 2016)
I didn't found any option in IntelliJ IDEA to recieve results of last command above. GitLab, TortoiseGit shows those differences, but IntelliJ IDEA shows that there is no changes... As a developer, I want to know what was changed by this merge, but IDEA looks like does not support this properly or I cannot find proper option to do this.
Please sign in to leave a comment.
Currently we show only the difference from both parents. Please see https://youtrack.jetbrains.com/issue/IDEA-148143 and related tickets.
I understand, You mean this option:
But I see, this is available only at file level, not for commits in VCS Log. Also this seems to be a little unintuitive, because I still not see result differences of this merge, only partial comparison with one parent.
This seems to me as huge feature drawback in comparison to your SVN integration. When I choose merge commit from project with SVN VCS I see all differences in one view, but in Git I can receive: some changes (when merge files needs to be manually edited) or no changes in VCS Log, which is not true at all... Other tools shows differences without problems for such merge commit, why IntelliJ IDEA cannot?
That would be really nice to have. I just hit a situation where deleted code was resurrected thanks to a bad merge. Without git-diff [sha1_hash]^1 [sha1_hash] and git-diff [sha1_hash]^2 [sha1_hash] it is practically impossible to find out what happened.
+1 for a pop-up just like the one in the file history view. Either that or some way to switch between git show, diff parent 1 and diff parent 2 in the left panel would be very welcome. Manually selecting the merge commit and one of its parents is painful and error prone.