You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Scott Palmer <sw...@gmail.com> on 2009/03/19 00:03:51 UTC
Minor feature request: --dry-run for update
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
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1351549
Re: Minor feature request: --dry-run for update
Posted by Travis Pouarz <sv...@castle.fastmail.fm>.
I've long thought this (--dry-run on update) a good idea.
I've a FAQ that I wrote up long ago for my users where I advise them
to run
svn merge -r BASE:HEAD --dry-run .
to tell them what files would get modified and how, including which
would have conflicts.
-Travis
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1366725
Re: Minor feature request: --dry-run for update
Posted by Scott Palmer <sw...@gmail.com>.
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"
Scott
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 <gs...@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 <ma...@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 <gs...@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 <sw...@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
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1360709
Re: Minor feature request: --dry-run for update
Posted by Mark Phippard <ma...@gmail.com>.
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 <gs...@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 <ma...@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 <gs...@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 <sw...@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
>>>>
>>>> ------------------------------------------------------
>>>> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1351549
>>>>
>>>
>>> ------------------------------------------------------
>>> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1355713
>>>
>>
>>
>>
>> --
>> Thanks
>>
>> Mark Phippard
>> http://markphip.blogspot.com/
>>
>
--
Thanks
Mark Phippard
http://markphip.blogspot.com/
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1359710
Re: Minor feature request: --dry-run for update
Posted by Greg Stein <gs...@gmail.com>.
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 <ma...@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 <gs...@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 <sw...@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
>>>
>>> ------------------------------------------------------
>>> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1351549
>>>
>>
>> ------------------------------------------------------
>> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1355713
>>
>
>
>
> --
> Thanks
>
> Mark Phippard
> http://markphip.blogspot.com/
>
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1359492
Re: Minor feature request: --dry-run for update
Posted by Greg Stein <gs...@gmail.com>.
On Mon, Mar 30, 2009 at 19:09, Alan Barrett <ap...@cequrux.com> wrote:
>> On Mar 19, 2009 5:55 PM, "Greg Stein" <gs...@gmail.com> wrote:
>> "svn st --show-updates" is what you're asking for. I really don't
>> understand why that doesn't work.
>
> On Fri, 20 Mar 2009, David Glasser wrote:
>> svn st -u only tells what would happen if you ran exactly "svn up";
>> without making the status CLI way uglier than the "svn up --dry-run"
>> proposal, it's not going to tell you what would happen with a more
>> complicated update command (with -r, --depth, etc).
>
> When "svn status -u" shows that a file has local modifications and
> also has new version in the repository, it doesn't indicate whether
> the local and repository changes would conflict. "svn merge --dry-run
> -rBASE:HEAD" is much closer to what "svn update --dry-run" should do.
Yes. There were a number of followups that pointed this out.
So yah... a --dry-run can make sense if a more thorough check is needed.
Cheers,
-g
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1484674
Re: Minor feature request: --dry-run for update
Posted by Alan Barrett <ap...@cequrux.com>.
> On Mar 19, 2009 5:55 PM, "Greg Stein" <gs...@gmail.com> wrote:
> "svn st --show-updates" is what you're asking for. I really don't
> understand why that doesn't work.
On Fri, 20 Mar 2009, David Glasser wrote:
> svn st -u only tells what would happen if you ran exactly "svn up";
> without making the status CLI way uglier than the "svn up --dry-run"
> proposal, it's not going to tell you what would happen with a more
> complicated update command (with -r, --depth, etc).
When "svn status -u" shows that a file has local modifications and
also has new version in the repository, it doesn't indicate whether
the local and repository changes would conflict. "svn merge --dry-run
-rBASE:HEAD" is much closer to what "svn update --dry-run" should do.
--apb (Alan Barrett)
Re: Minor feature request: --dry-run for update
Posted by David Glasser <gl...@davidglasser.net>.
svn st -u only tells what would happen if you ran exactly "svn up"; without
making the status CLI way uglier than the "svn up --dry-run" proposal, it's
not going to tell you what would happen with a more complicated update
command (with -r, --depth, etc).
--dave
On Mar 19, 2009 5:55 PM, "Greg Stein" <gs...@gmail.com> wrote:
"svn st --show-updates" is what you're asking for. I really don't
understand why that doesn't work.
Why introduce a new concept? (ie. dry run on an update)
Cheers,
-g
On Fri, Mar 20, 2009 at 00:57, Scott Palmer <sw...@gmail.com> wrote:
> The more I think about it, --dry-run on update seems to be the right place
> for this. Merge and update are essentially the same operations - just the
> source of the incoming changes are different.
>
> Scott
> > On 19-Mar-09, at 10:50 AM, Mark Phippard <ma...@gmail.com> wrote: >
>> So I assume you mean s...
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1359505
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1365126
Re: Minor feature request: --dry-run for update
Posted by Greg Stein <gs...@gmail.com>.
"svn st --show-updates" is what you're asking for. I really don't
understand why that doesn't work.
Why introduce a new concept? (ie. dry run on an update)
Cheers,
-g
On Fri, Mar 20, 2009 at 00:57, Scott Palmer <sw...@gmail.com> wrote:
> The more I think about it, --dry-run on update seems to be the right place
> for this. Merge and update are essentially the same operations - just the
> source of the incoming changes are different.
>
> Scott
>
> On 19-Mar-09, at 10:50 AM, Mark Phippard <ma...@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 <gs...@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 <sw...@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
>>>>
>>>> ------------------------------------------------------
>>>>
>>>> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1351549
>>>>
>>>
>>> ------------------------------------------------------
>>>
>>> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1355713
>>>
>>
>>
>>
>> --
>> Thanks
>>
>> Mark Phippard
>> http://markphip.blogspot.com/
>
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1359505
Re: Minor feature request: --dry-run for update
Posted by Scott Palmer <sw...@gmail.com>.
The more I think about it, --dry-run on update seems to be the right
place for this. Merge and update are essentially the same operations -
just the source of the incoming changes are different.
Scott
On 19-Mar-09, at 10:50 AM, Mark Phippard <ma...@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 <gs...@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 <sw...@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
>>>
>>> ------------------------------------------------------
>>> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1351549
>>>
>>
>> ------------------------------------------------------
>> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1355713
>>
>
>
>
> --
> Thanks
>
> Mark Phippard
> http://markphip.blogspot.com/
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1359107
Re: Minor feature request: --dry-run for update
Posted by Mark Phippard <ma...@gmail.com>.
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 <gs...@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 <sw...@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
>>
>> ------------------------------------------------------
>> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1351549
>>
>
> ------------------------------------------------------
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1355713
>
--
Thanks
Mark Phippard
http://markphip.blogspot.com/
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1355820
Re: Minor feature request: --dry-run for update
Posted by Greg Stein <gs...@gmail.com>.
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 <sw...@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
>
> ------------------------------------------------------
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1351549
>
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1355713