adding a directory from another bzr repository with full history

John Arbash Meinel john at arbash-meinel.com
Thu Jul 31 16:03:06 BST 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

David Garamond wrote:
| hi all,
|
| this should be simple, but for some reason i cannot find the way to do
| this. i have repo1 and repo2, and in the name of refactoring i want to
| move repo2 into repo1/subdir, with full repo2's history added into
| repo1's history.
|
| how do i do this in bazaar?
|
| regards,
| dave
|
|

There are 2 ways, provide you want to bring in the whole history of the
other project.

With no addons, you can do:

cd project1
bzr merge -r 0..-1 ../project2

This will put everything into the root directory, so you then need to do:
bzr mkdir project2
bzr mv files from proj2 into project2/
bzr commit -m "Bring in project2"

It is a bit of a pain, but it generally works.

Another option is to use the "lp:bzr-merge-into" plugin, and then you get:

bzr merge-into ../project2 project2

Which basically does the above, without you having to do the work of
sorting out your root directory.

John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkiR1CoACgkQJdeBCYSNAANfnQCdG98veAYFKnG5sBLxELj24HA+
AewAn08N+f6ETjc0JcXEzeGAt/wiEuiR
=Kpq+
-----END PGP SIGNATURE-----



More information about the bazaar mailing list