Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Seeing a combined diff of many commits in subversion?

Tags:

svn

I have been asked to review the changes made in SVN revision number 123, 178, 199, 245 and 288 - which are all the commits related to a specific feature. What is the reasonable way to approach this ? I suppose I really want to see the collected diff in some way, but I'm open to suggestions. We're on revision 400 right now.

Edit: I like to know how to do things from the command line in subversion, but any solution that works in eclipse or intellij idea (or any separate application) is also welcome. I'm also deliberately open on what I can realistically hope to automate/get tool support for since I really don't see how to do this in a smart way.

like image 522
krosenvold Avatar asked Jan 21 '09 17:01

krosenvold


People also ask

How can I see svn commit changes?

The Commit Dialog Select any file and/or folders you want to commit, then TortoiseSVN → Commit.... The commit dialog will show you every changed file, including added, deleted and unversioned files.

What is the use of svn diff command?

The svn diff command reveals the differences between your working copy and the copy in the master SVN repository.

How do I find previous versions in svn?

Use the revision log dialog Select the file or folder in which you need to revert the changes. If you want to revert all changes, this should be the top level folder. Select TortoiseSVN → Show Log to display a list of revisions. You may need to use Show All or Next 100 to show the revision(s) you are interested in.


3 Answers

After digging around in IntelliJ idea I found a nice solution to this:

Select Version Control | Show Changes View.

On the left hand side you select repository and click all of the revisions you want to review.

In the right hand pane you will get a list of all the files that are affected by the revisions you have selected. When you choose "diff" you will see the internal changes in the selected changesets. Internal re-works that occur within the commits are not shown (as can be expected)

like image 136
krosenvold Avatar answered Nov 15 '22 20:11

krosenvold


Generate five distinct commits, and combine them all with combinediff from patchutils.

like image 24
squadette Avatar answered Nov 15 '22 21:11

squadette


I asked a similar question about extracting relevant changes for code review but didn't get a satisfactory answer. The closest I've come to a solution is to do what I mentioned, create a temporary branch and cherry-pick the interesting commits into that temporary branch. If they combine cleanly, then the whole delta can be reviewed at once. In the event that they don't combine cleanly and rely on another unrelated change, perhaps that means the whole lot should be reviewed all at once anyway.

like image 37
Greg Hewgill Avatar answered Nov 15 '22 21:11

Greg Hewgill