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

RE: Does SubVersion allows to share a file/revision among multiple paths ?

From: Jay Glanville <jay.glanville_at_naturalconvergence.com>
Date: 2004-07-15 18:47:45 CEST

> >All three paths (projects) need that mls.cpp file. Is there a way to
> >have 'mls.cpp' appear in all three paths but being a single entity ?
> >That is: if mls.cpp is modified by a commit touching path "sub1", the
> >mls.cpp in sub2 and sub3 are instantly in synch too ?
> >
> >
> You can't do this for individual files. You can use "externals"
> definitions (look up svn:externals in the book) to have one folder
> always pull in folders from another location (even another
> repository).
> In that case you probably still would want to create a "common"
> location, and have the projects that use it define that
> "common" folder
> as an external.
>
> >Is this achievable with current version 1.0x ?
> >Is this part of 1.1 ?
> >What are the plans ?
> >Is this even a good idea ?
> >
> >
> The only version control system I know of which supports what you're
> talking about is Visual SourceSafe's "Links", but I would
> argue this is
> a dangerous feature to use. I know it has created much
> confusion for my
> team at work.

Actually, I know that Borland's StarTeam has this 'sharing'
functionality (and possibly even ClearCase, but don't quote me on that).

We use this sharing functionality quite a bit to help maintain a
project's third-party dependencies. For example, have a look at the
following tree:

- root
  - tps
    - junit
      - 3.8
        - docs
        - src.jar
        - junit.jar
    - httpunit
      - 1.5.4
        - docs
        - src.jar
        - httpunit.jar
  - webtest_one
    - src ...
    - lib
      - junit.jar -> /root/tps/junit/3.8/junit.jar
      - httpunit.jar -> /root/tps/httpunit/1.5.4/httpunit.jar
  - webtest_two
    - src ...
    - lib
      - junit.jar -> /root/tps/junit/3.8/junit.jar
      - httpunit.jar -> /root/tps/httpunit/1.5.4/httpunit.jar

This gives us several things:
- the flexability to have a single point of storage for all our
3-party-software (giving us the libs together with it's source and docs)
- each project has a library directory, showing/storing all the tps it
depends on
- our build scripts can now be made more generic:
  - step one: add all jars in project lib dir to classpath ...

Unfortunatly, Subversion can't do this for us (it's not a blocking issue
for us, but it definatly would be nice). Once Subversion changes
svn:external to be able to use a single file as opposed to a single
directory, I'll be quite happy (but not as happy as I'll be when they
introduce locking ... ;-) ).

JDG

--
Jay Glanville
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Thu Jul 15 18:49:04 2004

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