146

How do I create a new branch with my working copy using TortoiseSVN?

I see the branch option, but I don't see a way to name it somehow.

Alexander Abakumov
  • 13,617
  • 16
  • 88
  • 129
the_drow
  • 18,571
  • 25
  • 126
  • 193

4 Answers4

238

Right click and open SVN Repo-browser:

Enter image description here

Right click on Trunk (working copy) and choose Copy to...:

Enter image description here

Input the respective branch's name/path:

Enter image description here

Click OK, type the respective log message, and click OK.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
BJ Patel
  • 6,148
  • 11
  • 47
  • 81
  • 14
    After this step, if you want to access the files of the revision, get the right click menu of the tags/branch folder. choose: SVN Update. Only then, the folder of Version2.45.5 is copied with its files in the folder. – lode Oct 24 '14 at 18:47
  • "Copy to... " does not appear on my menu - Versio n1.9.5 Build 27581 – NealWalters Feb 08 '18 at 16:51
  • 2
    @NealWalters - this may vary on the Windows SVN client you are using. On mine, I have "SVN Branch/Tag". If you don't see that either, then check go into the settings of your SVN client and check what options are enabled for the "Context Menu". – HPWD Mar 27 '18 at 18:12
66

In the Repository Browser of TortoiseSVN, find the branch that you want to create the new branch from. Right-click, Copy To.... and enter the new branch path. Now you can "switch" your local WC to that branch.

Chris Thornton
  • 15,620
  • 5
  • 37
  • 62
64

Branches in SVN are essentially directories; you don't name the branch so much as choose the name of the directory to branch into.

The common way of 'naming' a branch is to place it under a directory called branches in your repository. In the "To URL:" portion of TortoiseSVN's Branch dialog, you would therefore enter something like:

(svn/http)://path-to-repo/branches/your-branch-name

The main branch of a project is referred to as the trunk, and is usually located in:

(svn/http)://path-to-repo/trunk
Blair Holloway
  • 15,969
  • 2
  • 29
  • 28
12

My solution if you work with the Trunk/ and Release/ workflow:

Right click on Trunk/ which you will be creating your Branch from:

Trunk

Select Branch/Tag:

Branch/Tag

Type in location of your new branch, commit message, and any externals (if your repository has them):

enter image description here

Andy J
  • 1,479
  • 6
  • 23
  • 40