I am using SharpSVN to access my subversion repository using SharpSVN, i need a means to create a branch programatically using SharpSVN, how is this done!!
To create a branch or a tag in a Subversion repository, do the following: From the main menu, choose VCS | Subversion | Branch or Tag. Alternatively, select the source folder in the SVN Repositories tool window and choose the Branch or Tag command from the context menu.
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.
Create a new directory and call it "trunk". Move all the files into this new directory. Then commit it. If you're using Eclipse, it "knows" that you've created new directories and moved files and sends the correct messages to SVN.
Usually a branch is created with svn copy <path> <URL>
or svn copy <URL1> <URL2>
.
With SharpSvn you can perform this operation using SvnClient.RemoteCopy()
. The function SvnClient.Copy()
is only used when the target is a local path.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With