Abstract (was Re: [Google SOC] Rebase command)

Stefano stefano at inventati.org
Wed Mar 26 18:34:04 CDT 2008


Patrick Mézard wrote:
> A special case being working with foreign VCS like Subversion. The push part will rely on this ability to rebase user changes against the upstream repository before committing them. So once the basic rebase command works correctly, we make it available programmatically.
>   
So we'll use rebasing to improve transparency between hg and foreign VCS?
>> The implementation will have to take in consideration several aspects, some of
>> them Mercurial related, other regarding Rebasing in general. 
>>  
>> Mercurial, that is based on the idea of immutable history, doesn't allow
>> revisions to be moved easily, so the simplest rebasing process could be
>> somewhere tricky. It could require to have transient/inconsistent states that
>> will be removed at the end of the process.
>>     
>
> Right about transient, but you will never set the repository in an inconsistent state.
>   
Ok, corrected.

>> More in general, a rebasing process could face some issues due to user
>> interruption and/or file conflicts. In the latter case the process will stop
>> and wait for user intervention, so it will be necessary to provide a way to
>> resume an interrupted process; in event of interruption/abortion the repository
>> must be left in a consistent state.
>> Moreover, a rebasing process should check if there are redundant commits (read
>> as 'already applied patches').
>>     
>
> I am not sure what you mean in the last sentence. I don't really expect rebase to detect commits are "redundant". But you are right the repository state may change between interruption and rebase must ensure it can still keep going properly.
>   

Well, git does that check and it makes sense... just think about a 
situation in which upstream contains
a/some patch/es you've made, in that case the rebase process should 
recognize and skip it/them.

Thank you so much for your corrections!

Stefano


More information about the Mercurial-devel mailing list