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

Re: Migrating to new repository layout

From: <pll_at_lanminds.com>
Date: 2003-09-09 20:51:52 CEST

In a message dated: Tue, 09 Sep 2003 14:34:24 EDT
Remi_Pelletier@dom.com said:

>What is the process of migrating an existing repository to a new layout.
>From a flat structure: (doh!)
> /svn/repos/projectA
>To a more useful structure such as:
> /svn/repos/root/projectA
> .../trunk
> .../branches
> .../tags
> /svn/repos/root/projectB
> .../trunk
> .../branches
> .../tags

You should be able to:

    mv /svn/repos/projectA /svn/repos/root

    svn mkdir file:///svn/repos/root/ProjectA
    svn mkdir file:///svn/repos/root/ProjectA/branches
    svn mkdir file:///svn/repos/root/ProjectA/tags
    svn mkdir file:///svn/repos/root/ProjectA/trunk
    for i in `svn ls file:///svn/repos/root | egrep -v '/'`
      svn mv file:///svn/repos/root/ProjectA/$i \
         file:///svn/repos/root/ProjectA/trunk -m"moved $i to trunk/"

At least, this worked for me on a test repo.

To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Tue Sep 9 20:52:52 2003

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.