Comparing two CVS revisions in Eclipse
Asked Answered
E

2

8

It finally started to annoy me enough to ask this question: how do I do a basic diff between two revisions of a file in CVS? Usually I want to compare the latest revision and some random old one. I'm using the Eclipse CVS plugin. When I use "compare with->Another branch or version..." from the selected file's (latest revision from HEAD or another branch) context menu, I get a list of branches, tags and dates but not revisions. Usually I have just created a date which I know is far enough in the past so I can compare the needed revisions but I thought that there must be a better way.

Estrada answered 16/9, 2008 at 12:14 Comment(0)
E
10

The answer is to show the file's history using context menu->Team->Show history, then choose two revisions and context menu for the selection->compare with each other.

Estrada answered 16/9, 2008 at 12:16 Comment(0)
U
2

There seems to be two main ways:

context menu->Team->Show history

which shows a linear history and you can select and compare between them, however it can be very bloated and hard to read when your project has lots of branches / tags. Personally i have found it less useful than:

context menu->Team->Show Commit history

Which seems to show the history of what has been committed to the specific branch/tag you are on. You can do it per file or per folder. The output is very similar but i find it clearer. You can click on a commit date and it will show you all the files (that you are interested in) that were committed on that date.

If you double click the file, it will then bring up another menu so that you can compare it with another file in the commit history

EDIT (i find if you double click the "other" file, it doesn't do anything, you need to click "OK" in the dialogue, which seems silly to me. This might be effected by the fact I have the beyond compare 3 plug in, im not sure if it behaves the same without it) EDIT

There is also a little button in the top right of the commit history window that allows you to switch to history view (but i always find it easy to read than the normal history view if i do it this way round)

Both should show you the comment added when committed and you should try and read about the differences between the but personally I haven't and its only form personal experience that i prefer commit history.

I apologize for not giving formal descriptions of each, this is purely from my personal experience of using them, i have not actually researched them both yet myself...

Unmanned answered 3/4, 2012 at 11:23 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.