<p>How do I create a branch in SVN?</p>

[{'answer_id': 2042, 'author': 'sparkes', 'author_id': 269, 'author_profile': 'https://Stackoverflow.com/users/269', 'pm_score': 9, 'selected': False, 'text': '<p>Create a new branch using the <code>svn copy</code> command as follows:</p>\n\n<pre><code>$ svn copy svn+ssh://host.example.com/repos/project/trunk \\\n           svn+ssh://host.example.com/repos/project/branches/NAME_OF_BRANCH \\\n      -m "Creating a branch of project"\n</code></pre>\n'}, {'answer_id': 2197, 'author': 'pix0r', 'author_id': 72, 'author_profile': 'https://Stackoverflow.com/users/72', 'pm_score': 4, 'selected': False, 'text': '<p>Normally you\'d copy it to svn+ssh://host.example.com/repos/project/branches/mybranch so that you can keep several branches in the repository, but your syntax is valid.</p>\n\n<p>Here\'s some advice on <a href="http://svnbook.red-bean.com/en/1.1/ch04s07.html" rel="noreferrer">how to set up your repository layout</a>.</p>\n'}, {'answer_id': 2207, 'author': 'basszero', 'author_id': 287, 'author_profile': 'https://Stackoverflow.com/users/287', 'pm_score': 4, 'selected': False, 'text': '<p>If you even plan on merging your branch, I highly suggest you look at this:</p>\n\n<p><a href="http://www.orcaware.com/svn/wiki/Svnmerge.py" rel="noreferrer">Svnmerge.py</a></p>\n\n<p>I hear Subversion 1.5 builds more of the merge tracking in, I have no experience with that. My project is on 1.4.x and svnmerge.py is a life saver!</p>\n'}, {'answer_id': 2310, 'author': 'Ronnie', 'author_id': 193, 'author_profile': 'https://Stackoverflow.com/users/193', 'pm_score': 10, 'selected': True, 'text': '<p>Branching in Subversion is facilitated by a very very light and efficient copying facility.</p>\n\n<p>Branching and tagging are effectively the same. Just copy a whole folder in the repository to somewhere else in the repository using the <code>svn copy</code> command.</p>\n\n<p>Basically this means that it is by convention what copying a folder means - whether it be a backup, tag, branch or whatever. Depending upon how you want to think about things (normally depending upon which SCM tool you have used in the past) you need to set up a folder structure within your repository to support your style.</p>\n\n<p>Common styles are to have a bunch of folders at the top of your repository called <code>tags</code>, <code>branches</code>, <code>trunk</code>, etc. - that allows you to copy your whole <code>trunk</code> (or sub-sets) into the <code>tags</code> and/or <code>branches</code> folders. If you have more than one project you might want to replicate this kind of structure under each project:</p>\n\n<p>It can take a while to get used to the concept - but it works - just make sure you (and your team) are clear on the conventions that you are going to use. It is also a good idea to have a good naming convention - something that tells you why the branch/tag was made and whether it is still appropriate - consider ways of archiving branches that are obsolete.</p>\n'}, {'answer_id': 17806877, 'author': 'Chamly Idunil', 'author_id': 2516131, 'author_profile': 'https://Stackoverflow.com/users/2516131', 'pm_score': 4, 'selected': False, 'text': '<p>Suppose you want to create a branch from a trunk name (as "TEST") \nthen use:</p>\n\n<pre><code>svn cp -m "CREATE BRANCH TEST" $svn_url/trunk $svn_url/branches/TEST\n</code></pre>\n'}, {'answer_id': 18588374, 'author': 'Parag Bafna', 'author_id': 944634, 'author_profile': 'https://Stackoverflow.com/users/944634', 'pm_score': 5, 'selected': False, 'text': '<pre><code>svn cp /trunk/ /branch/NEW_Branch\n</code></pre>\n\n<p>If you have some local changes in trunk then use <code>Rsync</code> to sync changes</p>\n\n<pre><code>rsync -r -v -p --exclude ".svn" /trunk/ /branch/NEW_Branch\n</code></pre>\n'}, {'answer_id': 21574545, 'author': 'Sonu Gupta', 'author_id': 3274732, 'author_profile': 'https://Stackoverflow.com/users/3274732', 'pm_score': 3, 'selected': False, 'text': '<ul>\n<li>Create a new folder outside of your current project. You can give it any name. (Example: You have a checkout for a project named "Customization". And it has many projects, like "Project1", "Project2"....And you want to create a branch of "Project1". So first open the "Customization", right click and create a new folder and give it a name, "Project1Branch").</li>\n<li>Right click on "Myproject1"....TortoiseSVN -> Branch/Tag.</li>\n<li>Choose working copy.</li>\n<li>Open browser....Just right of parallel on "To URL".</li>\n<li>Select customization.....right click then Add Folder. and go through the folder which you have created. Here it is "Project1Branch". Now clik the OK button to add.</li>\n<li>Take checkout of this new banch.</li>\n<li>Again go to your project which branch you want to create. Right click TorotoiseSVN -> branch/tag. Then select working copy. And you can give the URL as your branch name. like {your IP address/svn/AAAA/Customization/Project1Branch}. And you can set the name in the URL so it will create the folder with this name only.\nLike {Your IP address/svn/AAAA/Customization/Project1Branch/MyProject1Branch}.</li>\n<li>Press the OK button. Now you can see the logs in ...your working copy will be stored in your branch.</li>\n<li>Now you can take a check out...and let you enjoy your work. :)</li>\n</ul>\n'}, {'answer_id': 22711648, 'author': 'chim', 'author_id': 673282, 'author_profile': 'https://Stackoverflow.com/users/673282', 'pm_score': 4, 'selected': False, 'text': '<p>Top tip for new SVN users; this may help a little with getting the correct URLs quickly.</p>\n\n<p>Run <code>svn info</code> to display useful information about the current checked-out branch.</p>\n\n<p>The URL should (if you run svn in the root folder) give you the URL you need to copy from.</p>\n\n<p>Also to switch to the newly created branch, use the <code>svn switch</code> command:</p>\n\n<pre><code>svn switch http://my.repo.url/myrepo/branches/newBranchName\n</code></pre>\n'}, {'answer_id': 35325400, 'author': 'Dave', 'author_id': 1235929, 'author_profile': 'https://Stackoverflow.com/users/1235929', 'pm_score': 5, 'selected': False, 'text': '<p>If you\'re repo is available via https, you can use this command to branch ...</p>\n\n<pre><code>svn copy https://host.example.com/repos/project/trunk \\\n       https://host.example.com/repos/project/branches/branch-name \\\n  -m "Creating a branch of project"\n</code></pre>\n'}, {'answer_id': 60880603, 'author': 'Prashanth', 'author_id': 6387425, 'author_profile': 'https://Stackoverflow.com/users/6387425', 'pm_score': 2, 'selected': False, 'text': '<p>Below are the steps to create a branch from trunk using TortoiseSVN in windows machine. This obviously needs TortoiseSVN client to be installed.</p>\n\n<ol>\n<li>Right Click on updated trunk from local windows machine</li>\n<li>Select TortoiseSVN</li>\n<li>Click branch/Tag</li>\n<li>Select the To path in SVN repository. Note that destination URL is updated according to the path and branch name given</li>\n<li>Do not create folder inside branches in repository browser</li>\n<li>Add branches path. For example, branches/</li>\n<li>Add a meaningful log message for your reference</li>\n<li>Click Ok, this creates new folder on local system</li>\n<li>Checkout the branch created into new folder</li>\n</ol>\n'}]
['https://Stackoverflow.com/questions/2041', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/269/']