confused about rebase

Giorgos Keramidas keramida at ceid.upatras.gr
Wed Nov 24 02:52:48 CST 2010


On Mon, 22 Nov 2010 15:04:42 -0500, Neal Becker <ndbecker2 at gmail.com> wrote:
>Neal Becker wrote:
>> Sorry, I'm still confused about how to setup this structure.  Lets
>> say I have clean vendor tar balls, and a set of patches.  What are
>> the steps I would use?
>
> I think I got it.
> 1. Start with a clean hg repo of the vendor tree (boost_1_44_0.dist)
> 2. create vendor branch
> 3. commit it
> 4. switch back to default branch
> 5. import each of my local patches to default
> 6. tar xzf boost_1_45_0.tar.bz2
> 7. *** switch back to vendor branch!!
> [nbecker at nbecker1 boost_1_44_0.dist]$ hg update boost
> copy revision info on top of clean vendor tree
> (Note we swiched to vendor branch in step 7 so we will be on vendor branch here)
> 8. cp -al boost_1_44_0.dist/.hg* boost_1_45_0/
> [nbecker at nbecker1 boost_1_45_0]$ hg branch boost
> 9. addremove to update
> [nbecker at nbecker1 boost_1_45_0]$ hg addremove

Before copying new snapshots of the vendor source it may be nice to
'clean' the old vendor sources with "rm -fr *" in the working directory
of the new import.

This way if the vendor has deleted any files between release N and N+1
"hg addremove" will pick them up as 'deleted' in the new import.

> 13. And it's just that easy :)

Yep. Once you 'get' what's going on behind the scenes, it's that easy
indeed.



More information about the Mercurial mailing list