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

Re: Minor feature request: --dry-run for update

From: Scott Palmer <swpalmer_at_gmail.com>
Date: Thu, 19 Mar 2009 23:09:49 -0400

That's right. Specifically "svn st -u" does NOT tell me what would
*happen in my working copy* if I did an update. It only tells me
there are incoming changes that may or may not mesh with the work I
have in progress.
I also don't think this introduces a new concept - the concept of a
dry run exists already in the context of merge - which is just another
way to pull changes in to you working copy. The concept when applied
to update is not really new, it is the exactly the same concept used
with merge --dry-run.

I suggest it as a feature because the concept already exists and I
suspect the implementation is rather straight forward as merge is
already doing the same thing. I could re-word the request as "why
doesn't --dry-run work with update?" Shouldn't --dry-run apply to
anything that is going to change my working copy? E.g. this should
also apply to "switch"


On 19-Mar-09, at 9:23 PM, Mark Phippard wrote:

> It knows which files have changed, but it does not know the "content"
> of that change so it could not tell you if update is going to be merge
> or produce a conflict. That is what the original request was about.
> Mark
> On Thu, Mar 19, 2009 at 8:51 PM, Greg Stein <gstein_at_gmail.com> wrote:
>> Hmm? 'svn st -u' contacts the server to ask "if I updated right now,
>> then what would happen?" ... that is *exactly* what Scott was asking
>> for.
>> I'm not sure that I understand what you mean by "It does not
>> currently
>> have the incoming changes available to know that." ... ?? why not?
>> Isn't it getting exactly that from the server?
>> Cheers,
>> -g
>> On Thu, Mar 19, 2009 at 15:50, Mark Phippard <markphip_at_gmail.com>
>> wrote:
>>> So I assume you mean svn st -u would be updated to indicate a
>>> conflict
>>> would occur? It does not currently have the incoming changes
>>> available to know that. Of course update can only produce a
>>> conflict
>>> if there are local modifications, so a "poor man's" version can be
>>> made with the current output by looking for incoming changes where
>>> there are also local mods.
>>> Mark
>>> On Thu, Mar 19, 2009 at 10:30 AM, Greg Stein <gstein_at_gmail.com>
>>> wrote:
>>>> I'd counter and say that 'svn status -u' (aka --show-updates)
>>>> should
>>>> learn to do that. No reason to add more switches :-)
>>>> On Thu, Mar 19, 2009 at 01:03, Scott Palmer <swpalmer_at_gmail.com>
>>>> wrote:
>>>>> Analogous to the --dry-run option for merge, having the same
>>>>> option
>>>>> for update would allow scripts and tools to test for incoming
>>>>> changes
>>>>> (similar to the eighth column in 'status') and detect when
>>>>> conflicts
>>>>> would happen, without introducing the conflicts into the working
>>>>> copy. This offers a means to give you a 'heads up' to potential
>>>>> problems and yet not force you to deal with conflict resolution
>>>>> immediately like a "real" update would.
>>>>> Scott

Received on 2009-03-20 12:13:59 CET

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