[DRAFT][RFC] Migrating to rich roots
John Arbash Meinel
john at arbash-meinel.com
Wed May 13 22:50:36 BST 2009
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Martin Albisetti wrote:
> So, Matt Nordhoff figured out a better plan for Launchpad, which
> preserved current stacked branches from breaking.
> The result is that we now have Loggerhead's trunk in 1.9-rich-root,
> and all current stacked branches still work!
>
> This is what we did for Loggerhead:
>
> $ bzr branch lp:~loggerhead-team/loggerhead/trunk
> $ cd trunk
> $ bzr reconcile
> # Use +junk to avoid LP's default stacking policy. Also, teams cannot
> own +junk branches.
^- Actually, I'm pretty sure that the last code rollout allows team
shared +junk branches. Not that it matters terribly here.
v- A comment here would be helpful
# Upload a pristine copy of the reconciled trunk
> $ bzr push lp:~mnordhoff/+junk/trunk
> $ bzr upgrade --1.9-rich-root
> $ bzr reconcile
> LP: Rename ~loggerhead-team/loggerhead/trunk to ~mnordhoff/+junk/trunk-rich
> LP: Rename ~mnordhoff/+junk/trunk to ~loggerhead-team/loggerhead/trunk
> $ hitchhiker lp:~mnordhoff/+junk/trunk-rich rename backup.bzr .bzr/backup.bzr
> $ hitchhiker lp:~mnordhoff/+junk/trunk-rich rename .bzr backup.bzr
> $ bzr push --use-existing-dir lp:~mnordhoff/+junk/trunk-rich
> LP: Rename ~mnordhoff/+junk/trunk-rich to ~loggerhead-team/loggerhead/trunk-rich
>
> Lines that start with "$" are shell commands.
> Lines that start with "LP:" are instructions for Launchpad's web UI.
> Lines that start with "#" are comments, duh.
>
> To get hitchhiker, bzr branch lp:hitchhiker.
>
So at the end of all of this, you just have a pristine 'trunk' branch
(which has had reconcile run on it).
And another branch which has been upgraded, but has a backup.bzr/ with
the old trunk in it.
Renaming the trunk => ~mnordhoff... will break stacked branches anyway.
So why not do it as:
$ bzr branch lp:loggerhead trunk
$ cd trunk
$ bzr reconcile
# Backup the pre-reconciled copy, and save any existing backup
$ hitchiker lp:loggerhead rename backup.bzr .bzr/old_backup\
$ hitchiker lp:loggerhead rename .bzr backup.bzr
# Upload the reconciled copy
$ bzr push lp:loggerhead --use-existing
$ bzr upgrade --1.9-rich-root
$ bzr push lp:~loggerhead-team/loggerhead/trunk-rich
I suppose you arguably want the 'backup.bzr' to be in the trunk-rich
directory?
John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAkoLQKwACgkQJdeBCYSNAAMVkwCeP5Qj5/yuFChReceBQURt4I69
QqsAn3bx+73f3Ag9LaOXhd+DIi3U8SJM
=MgZR
-----END PGP SIGNATURE-----
More information about the bazaar
mailing list