Creating a new repo from old one

Asked by avi

Hi all. I am very new to bazaar & I am really enjoy using it. The versioning thing is so powerful & makes stuff easy :D

I have a bazaar repo, lets call it 'foo'. Under foo repo I have a directory, lets call it projects.

so, I want to create a separate bazaar repo with only porjects directory & I want to retain the log too. I mean to say, everything that is related to project folder present in log file, should be available with this new repo.

Hope I am clear. Thank you in advance :)

Question information

Language:
English Edit question
Status:
Answered
For:
Bazaar Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
John A Meinel (jameinel) said :
#1

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

On 2013-07-15 17:11, avi wrote:
> New question #232474 on Bazaar:
> https://answers.launchpad.net/bzr/+question/232474
>
> Hi all. I am very new to bazaar & I am really enjoy using it. The
> versioning thing is so powerful & makes stuff easy :D
>
> I have a bazaar repo, lets call it 'foo'. Under foo repo I have a
> directory, lets call it projects.
>
> so, I want to create a separate bazaar repo with only porjects
> directory & I want to retain the log too. I mean to say, everything
> that is related to project folder present in log file, should be
> available with this new repo.
>
> Hope I am clear. Thank you in advance :)
>

You can look at "bzr split" to see if that fits what you want. Or just do:

bzr branch repo new-repo
cd new-repo
rm *
bzr revert projects
bzr mv projects/* .
bzr rm projects
bzr commit -m "Just projects"

Which is roughly equivalent of what 'bzr split' does.

It isn't possible to have the "same" commits without the rest of the
history because the history records the shape of the whole tree, not
just a subdirectory.

It would be theoretically possible to create a new history that has
all the changes that only affected the subdirectory be replayed in it,
but we do not have an automated way of creating this.

John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.13 (Cygwin)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iEYEARECAAYFAlHk+Y0ACgkQJdeBCYSNAAM+jwCfc8mjoDwE0ejY14wTJmQV9dRR
4GsAnio27z2XZ6cStBVGm65OvjGZ6hnP
=H3/S
-----END PGP SIGNATURE-----

Can you help with this problem?

Provide an answer of your own, or ask avi for more information if necessary.

To post a message you must log in.