svn copy [BRANCH-FROM-URL] [BRANCH-TO-URL] -m <COMMIT-LOG-MESSAGE>
svn copy [^/PATH-TO-BRANCH-FROM] [^/PATH-TO-BRANCH-TO] -m <COMMIT-LOG-MESSAGE>
As you might have noticed, we use svn copy
command to create branches, tags and shelves (we'll skip mentioning tags and shelves in the next paragraphs). This is the same command used to copy items in your working copy and into the repository.
svn copy
is used for branching because, branch is technically a copy of the source you copy from. However, this is not an ordinary copy are familiar with when copying files on your local file system. Branches in Subversion are so called "Cheap Copies" that are similar to symlinks. Therefore, creating a new branch takes minimal time to complete and takes practically no space in the Subversion repository. Create branches and use them for any change you want regardless of the change's size and scope.
svn copy
can be shortened to svn cp
as Subversion has aliases for most commands.