[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Give us instructions to create a new repository with the branch code of a old repository

From: Ryan Schmidt <subversion-2009d_at_ryandesign.com>
Date: Sat, 28 Nov 2009 17:37:50 -0600

On Nov 28, 2009, at 07:01, Lalitha Prasad wrote:

> Previously we have only one repository "repo1" in our svn repository directory and we made our WebDav to point directly to the repository itself, i.e. /home/repos/repo1.
>
> With our new requirement, we have created 2 new repositories repo1_new and repo2. Now we have changed the svnpath of webdav to point to the parent directory.
>
> Up to this every thing worked fine.
>
> But when we tried to switch our working copy to the new repo_new(both repo1 and repo_new have same code but with different versions), then we are getting error.
>
> Our repo1_new is like a mirror to the repo1.

How was repo1_new created from repo1? Do they have the same UUID? Do they have the same revision numbers?

> Detailed information:
> Previously, our workspace used to point to the url http://sample.com/svn/branches/branch1.
> Now we need to switch to the url http://sample.com/svn/repo1_new/trunk

You're trying to do two things at once. You need to do them separately. First you need to relocate the working copy so that portion of the URL that points to the root of the repository is updated:

svn switch --relocate http://sample.com/svn http://sample.com/svn/repo1_new

(the repository root used to be at /svn and now it is at /svn/repo1_new)

Then you can switch the part after the repository URL, if desired. For example if you want to switch from branch1 to trunk, you do:

svn switch http://sample.com/svn/repo1_new/trunk

(the working copy has now been switched from wherever it was (branches/branch1) to trunk)

> We have tried the command svn switch http://sample.com/svn/repo1_new/trunk from the workspace. This has thrown us error like this,
> Error:
> svn: 'http://sample.com/svn/branches/branch1'
> is not the same repository as
> 'http://sample.com/svn/repo1_new/trunk'
>
> How can solve this one and make my workspace to switch to the new url?

If the above doesn't help, then it sounds like they are not the same repository. If they aren't, then you can't switch or relocate; you must check out new working copies.

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2425142

Please start new threads on the <users_at_subversion.apache.org> mailing list.
To subscribe to the new list, send an empty e-mail to <users-subscribe_at_subversion.apache.org>.
Received on 2009-11-29 00:38:40 CET

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.