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

RE: Requesting a New Feature

From: Bob Archer <Bob.Archer_at_amsi.com>
Date: Thu, 29 Jul 2010 12:15:24 -0400

> On 29.07.2010 16:28, Bob Archer wrote:
> >> Sorta kinda. Let's use our own tree as an example. We start
> with
> >> an empty checkout of the root of our project:
> >>
> >> $ svn co --depth empty
> http://svn.apache.org/repos/asf/subversion
> >> \ subversion $ cd subversion
> >>
> >> Now you decide that you want the trunk code for our cmdline
> tests
> >> (and only that code). You can do this today by the following
> >> lengthy process:
> >>
> >> $ svn up --depth empty trunk $ svn up --depth empty
> >> trunk/subversion $ svn up --depth empty trunk/subversion/tests $
> >> svn up trunk/subversion/tests/cmdline
> >>
> >> (IIRC, --depth and --set-depth are equivalent here because this
> >> behavior is more checkout-like than update-like.)
> >>
> >> Alternatively, I *suspect* you could do this:
> >>
> >> $ svn up --depth empty trunk trunk/subversion
> >> trunk/subversion/tests $ svn up trunk/subversion/tests/cmdline
> >>
> >> So, fewer commands, but still an annoying approach. Elango is
> >> wondering why 'svn update' doesn't add missing-but-needed parent
> >> directories (at depth=empty) by default. Why can't the above be
> >> shortened to just:
> >>
> >> $ svn up trunk/subversion/tests/cmdline
> >>
> >> ?
> >>
> >> I think that's a fair question to ask. Note that if we like the
> >> idea but don't wish to make it the default behavior, we have the
> >> -- parents option we can employ here to toggle it:
> >>
> >> $ svn up --parents trunk/subversion/tests/cmdline
> >>
> >
> > I see... I understand what he is saying now. I misunderstood from
> the
> > first paragraph him saying he wanted it to "update" sub-folders
> so I
> > assumed they were already checked out.
> >
> > I guess I am spoiled because in TortoiseSVN you can do this very
> > easily by just selecting the folder in the repository browser,
> > choosing Update to revision, select HEAD and Fully Recursive and
> it
> > gets all the parent folders automatically too.
>
> That's because TSVN does the lengthy process of updating each
> intermediate folder individually.
> So it does the:
> $ svn up --depth empty trunk
> $ svn up --depth empty trunk/subversion
> $ svn up --depth empty trunk/subversion/tests
> $ svn up trunk/subversion/tests/cmdline
> without asking the user but just does this (if the folders don't
> exist yet).
>
> But I would be happy if the svn lib would do that automatically
> with a
> new flag.
>
> Stefan

Yes, I know and kudos to TSVN... while I am perfectly adept at the svn command line I still use TSVN cause it does much of the heavy lifting for you if you are doing anything more than a basic svn up or svn ci.

BOb

Received on 2010-07-29 18:16:03 CEST

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.