Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to create a branch of an old revision with TortoiseSVN?

I have a repository where in revision 1 the folders trunk, branches and tags were added. The source was kept in trunk. Revision 7 happened, and development continued up to revision 16. Now I have to continue to work on revision 7, so I want to create a branch off of revision 7.

Here is how I tried to do this: Using TortoiseSVN, I select trunk in the repository browser, open "Show log", select revision 7 and right-click "Create branch/tag from revision". The Copy (Branch / Tag) dialog appears with FROM-URL set to trunk and I enter .../branches/new_branch_name as the To-URL. "Specific revision in repository" is checked and set to 7.

Now I get an error saying "Path ...../trunk does not exist in revision 7". But trunk was definitely created in revision 1 and if I look at the changed files of revision 7 in the "Show log" dialog, I can see that the files are added/modified in trunk.

What am I doing wrong?

like image 729
Holgerwa Avatar asked Aug 07 '09 19:08

Holgerwa


People also ask

How do I branch with TortoiseSVN?

Select the folder in your working copy which you want to copy to a branch or tag, then select the command TortoiseSVN → Branch/Tag.... If you can't remember the naming convention you used last time, click the button on the right to open the repository browser so you can view the existing repository structure.

How do I merge two svn revisions?

To merge a range of revisions, use svn merge -r start:end from to where start and end are revision IDs. This will merge all revisions starting at start+1 up to and INCLUDING end . Note: it will NOT include the first revision (ex: -r3:45 will merge 4 through 45).

Which is the command used to create branches svn?

Creating a branch is simple. All you need to do is make a copy of your project using "svn copy". This command will require the URL of your project's /trunk directory as well as the URL of the directory where you want to create your branch. This location will virtually always be inside of your /branches directory.


1 Answers

  • Open the repository browser.
  • Go to the root directory of the repository.
  • Click the "revision" button (it says "HEAD") and from the dialogue select the revision in question
  • Right drag-and-drop the "trunk" directory to the "branches" directory and select "Copy and rename item to here".
  • Type in the name of the new directory.
  • Write a log message.
like image 97
Milen A. Radev Avatar answered Oct 18 '22 18:10

Milen A. Radev