tags:

views:

149

answers:

3

Hi,

Following action only creat branch from head revision of the trunk.How to create branch from a specified revision? Thanks.

$ svn copy http://svn.example.com/repos/calc/trunk \
       http://svn.example.com/repos/calc/branches/my-calc-branch \
  -m "Creating a private branch of /calc/trunk."
+2  A: 
$ svn copy http://svn.example.com/repos/calc/trunk@192 \
   http://svn.example.com/repos/calc/branches/my-calc-branch \
   -m "Creating a private branch of /calc/trunk."

Where 192 is the revision you specify

You can find this information from the SVN Book, specifically here on the page about svn copy

Dan McGrath
A: 

append the revision using an "@" character:

svn copy http://src@REV http://dev

Or, use the -r [--revision] command line argument.

eqbridges
+1  A: 

Check out the help command:

svn help copy

  -r [--revision] arg      : ARG (some commands also take ARG1:ARG2 range)
                             A revision argument can be one of:
                                NUMBER       revision number
                                '{' DATE '}' revision at start of the date
                                'HEAD'       latest in repository
                                'BASE'       base rev of item's working copy
                                'COMMITTED'  last commit at or before BASE
                                'PREV'       revision just before COMMITTED
Typeoneerror