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

Re: Checkouts of subsets of the tree

From: Garrett Rooney <rooneg_at_gmail.com>
Date: 2004-06-25 18:48:34 CEST

On Fri, 25 Jun 2004 12:32:57 -0400, Mark Bohlman <mbohlman@tcicredit.com> wrote:

> What would be nice would be something like a concrete example of
> being able to get from two repositories a working set of code. Say I'm
> using Java, and want to get the source we develop out of
> http://repos/trunk/src and the needed vendor jars out of
> http://vendor/jars. In my working copy I'd want to be able to do a
> "svn co http://repos/trunk/src" and then run ant or make to do a full
> build, picking up the needed jars/libraries into the proper location.
> Or a similar such scenario, for C/C++ or whatever.
>
> Having a concrete example to follow on doing something like this
> would really help make it clear what was needed by the user, and I think
> a lot of us using Subversion would benefit.

One way to do what you seem to be looking for might be something like
this. Note that this is not using svn:externals (I'm not a big fan of
it honestly), and it does introduce another step into the checkout
process, although that could be scripted pretty easily.

your top level repository layout looks like this:

/
 trunk/
  libs/
 libs/
  win32/
  macosx/

So your top level directory has a 'trunk' directory that holds your
main project. Then there's also a top level 'libs' directory, and
inside that are subdirectories for each operating system you support.
Inside each of those you would put system dependent libraries. Within
the trunk there's an empty libs directory that you will replace with
the appropriate platform specific libs subdirectory. The checkout
process looks like this:

$ svn co file:///tmp/repos/trunk foo
A foo/libs
Checked out revision 3.
$ cd foo
$ svn switch file:///tmp/repos/libs/win32 libs
At revision 3.
$ svn st
    S libs
$ svn info libs | grep URL
file:///tmp/repos/libs/win32
$

So first you check out the trunk, then you switch the platform
specific subdirectory to whatever is appropriate for your current
platform. Is this close to what you were looking for?

-garrett

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Fri Jun 25 18:54:01 2004

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.