Moving a project

View: New views
3 Messages — Rating Filter:   Alert me  

Moving a project

by Palmer, Eric :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

We had a contractor develop a project and he used his own SVN repository.  The project is part of a larger set of projects in this SVN repository.  Is there a way to move just that project and all its revisions to another repository that already has other projects within it?

We have https to both repositories.

thanks

Eric



------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/smartsvn/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/smartsvn/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:smartsvn-digest@...
    mailto:smartsvn-fullfeatured@...

<*> To unsubscribe from this group, send an email to:
    smartsvn-unsubscribe@...

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/


RE: Moving a project

by Greg Gibeling :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

        I don't think SmartSVN can help you with this, but fortunately it's
not too hard.  I've done it many times to consolidate smaller repositories.

        First run "svnadmin dump"
(http://svnbook.red-bean.com/en/1.5/svn.ref.svnadmin.c.dump.html) on the
repository you'll be getting rid of, the one created by the contractor.
Since you only want a part of that repository, you'll need to use
svndumpfilter
(http://svnbook.red-bean.com/en/1.5/svn.ref.svndumpfilter.html) to include
only those parts you need.  Finally "svnadmin load"
(http://svnbook.red-bean.com/en/1.5/svn.ref.svnadmin.c.load.html) can be
used with the "--parent-dir" option to load the dump into your repository at
an appropriate location.
        Two things to note:
        1) After performing the load, you may need to move things around to
get them exactly where you wanted.  In particular if the project directory
you wanted was nested deep in the contractor's repository, you'll see all
the parent directories.  Don't bother trying to get rid of them until you've
loaded the files into your repository (editing dumps in creative ways is
theoretically possible, but can be quite painful unless you're an SVN
expert).  Instead use the SmartSVN repository browser after the load to move
things around.
        2) If the contractor moved a lot of files in and out of this project
while it was in their repository your version history may be a little odd.
In particular the dumpfilter will (to my knowledge) take a move of a file
out of the included file set, followed by a move of that file back into the
included file set and turn that into a delete followed by an unrelated add.

-Greg

> -----Original Message-----
> From: smartsvn@... [mailto:smartsvn@...] On
> Behalf Of Eric P
> Sent: Wednesday, August 12, 2009 4:08 AM
> To: smartsvn@...
> Subject: [smartsvn] Moving a project
>
> We had a contractor develop a project and he used his own SVN
> repository.  The project is part of a larger set of projects in this
> SVN repository.  Is there a way to move just that project and all its
> revisions to another repository that already has other projects within
> it?
>
> We have https to both repositories.
>
> thanks
>
> Eric
>
>
>
> ------------------------------------
>
> Yahoo! Groups Links
>
>
>



------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/smartsvn/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/smartsvn/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:smartsvn-digest@...
    mailto:smartsvn-fullfeatured@...

<*> To unsubscribe from this group, send an email to:
    smartsvn-unsubscribe@...

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/


Re: Moving a project

by Palmer, Eric :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Greg,

Wow thanks. This is very helpful.  I'm new to SVN and you have made my life much better today.

May the peace of a thousand butterflies make your life better.

Eric


On 8/12/09 9:37 AM, "Greg Gibeling" <gdgib@...> wrote:





I don't think SmartSVN can help you with this, but fortunately it's
not too hard.  I've done it many times to consolidate smaller repositories.

First run "svnadmin dump"
(http://svnbook.red-bean.com/en/1.5/svn.ref.svnadmin.c.dump.html) on the
repository you'll be getting rid of, the one created by the contractor.
Since you only want a part of that repository, you'll need to use
svndumpfilter
(http://svnbook.red-bean.com/en/1.5/svn.ref.svndumpfilter.html) to include
only those parts you need.  Finally "svnadmin load"
(http://svnbook.red-bean.com/en/1.5/svn.ref.svnadmin.c.load.html) can be
used with the "--parent-dir" option to load the dump into your repository at
an appropriate location.
Two things to note:
1) After performing the load, you may need to move things around to
get them exactly where you wanted.  In particular if the project directory
you wanted was nested deep in the contractor's repository, you'll see all
the parent directories.  Don't bother trying to get rid of them until you've
loaded the files into your repository (editing dumps in creative ways is
theoretically possible, but can be quite painful unless you're an SVN
expert).  Instead use the SmartSVN repository browser after the load to move
things around.
2) If the contractor moved a lot of files in and out of this project
while it was in their repository your version history may be a little odd.
In particular the dumpfilter will (to my knowledge) take a move of a file
out of the included file set, followed by a move of that file back into the
included file set and turn that into a delete followed by an unrelated add.

-Greg

> -----Original Message-----
> From: smartsvn@... <mailto:smartsvn%40yahoogroups.com>  [mailto:smartsvn@... <mailto:smartsvn%40yahoogroups.com> ] On
> Behalf Of Eric P
> Sent: Wednesday, August 12, 2009 4:08 AM
> To: smartsvn@... <mailto:smartsvn%40yahoogroups.com>
> Subject: [smartsvn] Moving a project
>
> We had a contractor develop a project and he used his own SVN
> repository.  The project is part of a larger set of projects in this
> SVN repository.  Is there a way to move just that project and all its
> revisions to another repository that already has other projects within
> it?
>
> We have https to both repositories.
>
> thanks
>
> Eric
>
>
>
> ------------------------------------
>
> Yahoo! Groups Links
>
>
>







------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/smartsvn/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/smartsvn/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:smartsvn-digest@...
    mailto:smartsvn-fullfeatured@...

<*> To unsubscribe from this group, send an email to:
    smartsvn-unsubscribe@...

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/