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

Re: [vote] pin-externals branch to trunk

From: Stefan Kueng <tortoisesvn_at_gmail.com>
Date: Thu, 29 Jan 2015 23:01:32 +0100

On 29.01.2015 22:45, Stefan Sperling wrote:
> On Thu, Jan 29, 2015 at 07:26:01PM +0100, Stefan Kueng wrote:
>> TortoiseSVN has such a feature. Of course, it doesn't work in an ideal way.
>> Here's what I do in TSVN:
>> The branch/tag dialog (the one that's shown for an 'svn copy') scans the
>> working copy for all external properties, and it does this recursively. It
> What happens if one or more recursive externals definitions end up looping
> back to an external that's already been traversed?

The same that happens if you try to checkout/update such a setting: an
infinite loop.
Since such a setup would not work anyway, why bother trying to handle it?

>> also checks the uuid of the repository. All externals that point to the main
>> repository (even the recursive ones) are then shown in a list at the bottom
>> of the dialog. Each external item (file or folder) is also scanned for the
>> highest revision. That's the revision the external is later tagged to.
>> The list has a checkbox for each item, so users can chose which external
>> they want to tag.
>> See here for a screenshot:
>> http://tortoisesvn.net/docs/release/TortoiseSVN_en/tsvn-dug-branchtag.html#tsvn-dug-branch-1
>> For copies made from a working copy, TSVN first modifies all external
>> properties locally, then creates the copy from the working copy. For copies
>> done directly on the repository, it first creates the copy, then modifies
>> each external property separately (which leads to multiple 'commits' - as I
>> said: not ideal).
>> Looking at svn_client_commit6(), it has two bool values to include file
>> and/or dir externals in the commit. So it seems to me that it might be
>> possible to change externals (that reside in the same repository)
>> recursively?
> Well, I'd rather avoid having to make commits to multiple repositories.
> If this feature only works for externals pointing at the same repository
> then it's quite limited, isn't it?

It's limited, but not as much as you might think. Such recursive
externals are most often used in company internal setups, and there they
all point to the same repository. So for all those, that's a big help
and really required.

>> Also, the current implementation of this feature does not allow to select
>> externals individually to tag. Would it be a good idea to extend this? Maybe
>> one API that returns a list of externals and their revision which they would
>> be tagged to, and then svn_client_copy6 would take that list (or a list with
>> only those items the user wants to tag) and then only tag those externals in
>> that list?
>> This way, TSVN could make use of this new APIs and drop its own (not ideal)
>> code.
> If you need something like this in the API we can definitely make it happen.
> But I'd rather not implement a recursive externals crawl in svn_client_copy().

A local crawl of a working copy is pretty fast.
And always remember: even if it's slow, it's much faster than the user
having to do this manually.


   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest interface to (Sub)version control
    /_/   \_\     http://tortoisesvn.net
Received on 2015-01-29 23:02:37 CET

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