svnrabbitvcs

How to checkout only a particular revision from svn?


I'm using Rabbit svn(RabbitVCS 0.16.0) and I would like to know how to checkout/export only the code committed in a particular revision? I don't want any piece of code committed before the particular revision. Any help is appreciated.


Solution

  • If you already have a working copy, you can use the "switch" command to change it to a particular revision number.

    If you don't have a working copy, the "checkout" dialog box has a "revision" field at the bottom. It's set to "HEAD" by default, but you can change the dropdown to "Number" and specify a revision number in the field next to it.


    If you're wanting the changes associated with a specific revision (in other words, a diff), you'll want to start with a working copy at the revision number in question using either of the above two methods. Then, from the diff menu, select "Show Changes". A dialog box with appear with two fields labeled "Revision". On both fields, change the drop-down to "Revision". Then, in the text field next to it, put the revision number in question for "Second" and the revision number minus one for "First". For example, to see the changes in r100, you would use 99 for "First" and 100 for "Second". After filling in the revisions, hit the "Refresh" button. You can now look at the changes for each individual file, or use the drop-down on the bottom left to download a single file containing all of the changes.

    If you have the command-line Subversion client installed, you can do this much more simply and don't even need a working copy on your local machine:

    svn diff svn://your_repository/your_branch -c 100