[PATCH 5 of 6] hg: add updatetotally skipupdate to examine destination before actual update

Pierre-Yves David pierre-yves.david at ens-lyon.org
Sat Mar 19 20:21:04 EDT 2016



On 03/19/2016 11:19 AM, Pierre-Yves David wrote:
>
>
> On 03/12/2016 04:02 AM, FUJIWARA Katsunori wrote:
>>
>> At Fri, 11 Mar 2016 23:14:04 +0000,
>> Pierre-Yves David wrote:
>>>
>>>
>>>
>>> On 03/11/2016 07:41 PM, FUJIWARA Katsunori wrote:
>>>> # HG changeset patch
>>>> # User FUJIWARA Katsunori <foozy at lares.dti.ne.jp>
>>>> # Date 1457724942 -32400
>>>> #      Sat Mar 12 04:35:42 2016 +0900
>>>> # Node ID 4ec341fd8f85ca07dc6f99d82c155e9d559be390
>>>> # Parent  231ea15298afd3e1a4347791d4eb904742bf8243
>>>> hg: add updatetotally skipupdate to examine destination before
>>>> actual update
>>>>
>>>> This is useful for client, which wants to show any message before
>>>> (abortion of) actual updating, for example.
>>>
>>> Patch 1-4 are on the clowncopter. Thanks
>>>
>>> I'm deeply confused about why this is useful and why the complexity is
>>> worth it. Can you elaborate on this?
>>
>> "hg pull --rebase" and "hg fetch" skip actual updating procedure (=
>> merge.update()), if update destination is current parent itself.
>>
>> (this series doesn't care "hg fetch", because corresponded code path
>> has issue and inefficiency to be fixed in my next series :-))
>>
>> Because "hg pull --rebase" also shows "nothing to rebase" or "nothing
>> to rebase - updating instead" message according to the destination of
>> update, just introducing "skip if update isn't needed" flag isn't
>> useful for this purpose (at least, if current behavior should be
>> kept).
>>
>> If invoking destupdate() twice is acceptable redundancy, this change
>> isn't needed.

We chatted about it at the sprint and as this only affect rebase, we'll 
use the redundancy approach.

-- 
Pierre-Yves David


More information about the Mercurial-devel mailing list