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

RE: How to update only selective subdirectories?

From: Johan Corveleyn <johan.corveleyn_at_uz.kuleuven.ac.be>
Date: Mon, 22 Jun 2009 23:28:53 +0200

> -----Oorspronkelijk bericht-----
> Van: baz themail [mailto:bazthemail_at_gmail.com]
> Verzonden: maandag 22 juni 2009 23:11
> Aan: Johan Corveleyn
> Onderwerp: Re: How to update only selective subdirectories?
> > On Mon, Jun 22, 2009 at 16:16, bazthemail<bazthemail_at_gmail.com> wrote:
> > > Hi,
> > >
> > > If I have a parent directory A, and many huge subdirectories, say B
> > to Z. If
> > > I am a developer who just want to update A\B to A\E and if i need to
> > sync
> > > directory A without syncing subdirectories F to Z, then what is the
> > best way
> > > to do it?
> >
> > svn up A\B A\C A\D A\E
> >
> > > Yes, I know you can highlight B to E in TSVN but thats not an option.
> >
> > The above does the exact same thing.
> Let me explain a little bit more. This is the actual request from
> developers. They only use TSVN at this time and they would like to
> be able to do as little as possible - Just update the parent
> directory A to update everything except the subdirectories that
> they do not want.

Yes, and this is exactly what sparse directories help you with: it remembers which subdirs you want, and which you don't. The depth settings of the different working copy directories are sticky, so that next time you do an update of A, only the subdirs you explicitly brought in are updated.

In svn command-line, it works like this:

svn co --depth=empty url/to/A A
cd A
svn up B C D E
After this, A is a sparse working copy, with only B, C, D and E under it.
If you now run "svn up" in A, it will only update B, C, D and E.
You can create such a sparse working copy with TSVN as well. Here's how I did it:
- First checkout A with depth set to empty.
- Then right-click in your A working copy, and open Repo-browser.
- In Repo-browser, select needed subdirs (ctrl-click to multi-select)
- Choose "Update to revision"
- In this dialog, you can select depth=infinity (or whatever the name of the option is in the TSVN dropdown)
After that, your A checkout will be a nice sparse working copy. Updating the root of it will only update what you need.
To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-06-22 23:29:45 CEST

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