I write code to analyze our Hg , and compare the results with TortoiseHg . I am having trouble understanding the behavior of TortoiseHg in case of a merge.
When I select the merge change set in TortoiseHg , the list of affected files shows only those files that had conflicts, unless I click the "Show All" button. At the very least, it looks like an intention based on what I can glean from the Internet, and from observing that the files shown on the list have a bi-directional arrow if I click the Show All button.
I try to imitate this by distinguishing each file in the change set for both parents and including only the file in my analysis if it is different from both parents. However, I come across files that TortoiseHg shows in the merge description, but which differ from only one parent. I also see that in TortoiseHg - the difference from the parent 1 or 2 shows the change, but the other parent does not.
I also tried to distinguish --git with the --git option to make sure that this is not a metadata change that I am missing, but that does not change the results at all.
To get information about a set of changes, I use:
hg log -v -r <rev> --removed --style xml
I take parents from a set of merge changes, and for each file in the merge do
hg diff -r <parent1> -r <rev> filename hg diff -r <parent2> -r <rev< filename
And I found that the TortoiseHg files show in the merge report summary, which I report as merged without conflicts.
Can anyone shed light on the discrepancy?
Update: I was able to reproduce this with the source code for TortoiseHg itself.
Clone from https://hg01.codeplex.com/tortoisehg Open the repo in tortoiseHg and select rev 12602 (58eb7c70). This merger with parents is 12599 (6c716caa) and 12601 (39c95a81).
TortoiseHg shows the tortoisehg / hgqt / repowidget.py file as the only conflicting file in the merge, but
hg diff -r 12599 -r 12602 tortoisehg/hgqt/repowidget.py
returns nothing, but
hg diff -r 12601 -r 12602 tortoisehg/hgqt/repowidget.py
displays two lines.