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

Re: [PATCH] make svnmucc consistently overwrite copy targets

From: Philip Martin <philip_at_codematters.co.uk>
Date: Fri, 07 Nov 2008 02:21:34 +0000

kmradke_at_rockwellcollins.com writes:

>> kmradke_at_rockwellcollins.com writes:
>
> I'll admit some of the examples are a little contrived. Our use
> case is fairly unique, but one must handle these corner conditions
> gracefully, even if they aren't the expected mode of operation.
>
> <rant>
> However, I've been getting a little tired of people saying
> "just write a script". This fails to address multiple clients and
> platforms that would need to be handled.
>
> I've submitted a patch, gathered feedback, been willing to
> change the patch, but I still hear "just write a script"...

You hear that from me because in my opinion that's the best solution
for your particular problem. "Other opinions are available" [smile at
camera].

> </rant>
>
> For example, in Unix, cp -f exists to make it an easier operation.

And Unix mkdir doesn't support it. The fact that svnmucc replaces
directories when using mod_dav_svn might well be a server bug.

> Yes, the user could have manually written scripts around cp to
> handle the manual unlinking if needed, but there was a perceived
> usefulness to allowing overwriting an existing file in one step.
>
> There have been multiple requests on the users list to be
> able to easily overwrite an existing tag.

svnmucc allows users to overwrite tags, they don't need your patch. I
originally wrote it to do more or less exactly that.

> Allowing a "force"
> operation doesn't force anyone to use it, but does make
> it easier to use for a certain group of people that need
> it.

You describe your use case as "fairly unique" so I guess it's a very
small group.

> I believe the functionality gains outweigh the minor
> added complexity, or I wouldn't have been willing to create
> an acceptable patch.
>
> I do not want to maintain wrapper scripts for multiple platforms.

There are several cross platform scripting languages.

> Long term this will be much more effort and pain than adding
> native support and does not help out the community.

It's certainly less work for you if we maintain it :)

> Which of these options have the highest possibility of acceptance:
>
> 1) Modify svnmucc cp to allow a --force behavior

It was a mistake for svn to use --force, it should have been
--force-xxx or --force=xxx.

How would this option behave when svnmucc combines multiple cp
actions? What about rm when the target doesn't exist? cp when the
source doesn't exist? cp when the parent of the target doesn't exist?
All of these things could get forced but I just don't see the need.
Are you going to make directory overwrite work over the other RA
layers?

> 2) Modify svn cp to allow a --force behavior

svn cp with URLs already has some unpredictable behaviour, I'm not
sure whether force would make it better or worse :)

> 3) Create a new tool based on svnmucc, add --force behavior
> and contribute to contrib?

That would be silly.

I remain unconvinced about your patch; perhaps somebody else will
venture an opinion?

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-11-07 03:29:59 CET

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.