splicemap to "inject" files?
Tom Udale
tom at ionoptix.com
Fri Aug 19 16:56:34 UTC 2011
Tom,
Thanks for the tips!
Tom
> On 19/08/2011 14:45, Tom Udale wrote:
>> Ok, that worked great for injecting a file (or whatever) into the
>> history. I was able to clone to some arbitrary revision in the past
>> (which I did not know about), add arbitrary commits to the clone and
>> then tack on the rest of the original history to the end of the clone.
>> It looked like this (I am using the notation main:x to indicate the
>> nodeid for main repository change set x in these examples):
>>
>> hg clone -r main:0 main clone
>> rem add whatever to clone
>> rem make splice file (child parent): main:1 clone:tip
>> hg convert --splicemap splice main clone
>>
>> That worked perfectly.
>>
>> So now to be a tad more sophisticated. To do this repeatedly without
>> having to re-clone every time, I can just add a --rev on the convert
>> right?
>>
>> For example, given our 0-5 change set repository, I want to inject
>> changes between CS 0-1 _and_ 4-5.
>>
>> Can I just
>>
>> rem --- first modify between 0-1 ---
>> hg clone -r main:0 main clone
>> rem add whatever to clone
>> rem make splice file with: main:1 clone:tip
>> hg convert --splicemap splice --rev main:4 main clone
>> rem clone should contain up to main:4 now
>>
>> rem --- now modify between 4-5 ---
>> rem add whatever else to clone
>> rem make splice file with: main:5 clone:tip
>> hg convert --splicemap splice main clone
>>
>> That should do it right? I can just go on and on pulling slices from
>> main onto clone until I have everything chip-chopped together.
>
> That should work fine AFAIK.
>
> Tom
--
Tom Udale
--------------------------
IonOptix LLC
309 Hillside St.
Milton, MA 02186
(617) 696-7335
--------------------------
tom at ionoptix.com
More information about the Mercurial
mailing list