It's all about the answers!

Ask a question

Diff in changeset with multiple changes is calculated between Final - Modify and Merge checkin


K M (38325251) | asked Nov 12 '15, 10:04 a.m.
Diff in changeset with multiple changes is calculated between Final - Modify and Merge checkin, should it not be calculated between Final - Modify and Initial? Does anybody have an answer for this? RTC ver 5.0.2

Test
I created a simple three line file and did multiple checkins in to a change set.

Change set History
Final -Modify
Merge
Modify
Modify
Initial

When I look at the changeset, using a browser, I see the diff is calculated between the Final - Modify and the Merge.

I first Notice this problem when trying to use RTC and Review Board, I kept getting invalid diffs.

Comments
K M commented Nov 16 '15, 1:04 p.m.

Anybody know about this?


Lily Wang commented Nov 18 '15, 11:43 p.m.

In my RTC 5.0.2 web client, the diff in the full change set is correct:


K M commented Nov 19 '15, 10:07 a.m.

It says initial to final, but the diff is actually between Final and Merge, if you create a simple three line file you can see this easier

This is what I mean by diff (@@ stuff), if you copy that diff and try to patch your Initial file it will fail.

One answer



permanent link
Chris McGee (50511117) | answered Nov 27 '15, 9:54 a.m.
FORUM MODERATOR / JAZZ DEVELOPER
The default file comparison in RTC SCM is between the latest/final state of the file in the change set and either the last merge state or initial, if there are no merge states. The reason for this is that in many cases when you do the diff you want to see the net effect of your own changes, not mixed with someone else's that you merged in with your changes. Showing the diff between the last merge state and the latest state should cancel out the other developer's changes leaving only your own and the result of the merges (manual or automatic).

If you truly want to compare the state that was there when the file was first checked in with the latest state of the file then you should be able to select both state and diff them in the change explorer view's check-in history section.

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.