On Mon, 2010-02-22 at 14:28 +0300, Dmitry Potapov wrote: > On Mon, Feb 22, 2010 at 10:56:47AM +0100, Jelmer Vernooij wrote: > > > > There is no need for that data to be added later for revisions that did > > not originate from Bazaar. All of the metadata that has to be stored > > will be known at the time the commit is created. Those commits that were > > made in Git later will not have any metadata that can not be represented > > in Git (they were made with Git, after all). > If so, I do not see why any metadata should be stored in Git at all. If > you can work without them then why do you want to add to Git? And then > how about commit that originated in Git then exported to Bazaar and then > imported back at Git? It is still originated in Git and thus should not > have any metadata despite being imported from Bazaar. Commits that originated in Git do not contain any Bazaar-specific metadata, even if they also lived in Bazaar at some point, because they could not have been set by Git at commit time. We would only add the metadata for revisions that did not come out of Git originally. We'd like to have the extra metadata in Git so that we can push Bazaar commits into a Git repository losslessly. If we can't do this losslessly then the identity of the commit changes just like it does in git if you aren't able to produce the same tree, blob and commit objects. > > Having a bzr/master ref means that the extra metadata will not always be > > copied around (unless git is patched), so if I push my work from Bazaar > > into Git, somebody works on it in Git and pushes a derived branch and > > then somebody else clones that derived Git branch into Bazaar again, I > > will not be able to communicate with that person's branch. > No matter how many times a branch was cloned, it is exactly same branch > (i.e. it consists of commits having exactly the same id). So, if you can > work with the original branch, you can work with any cloned branch. So, > I see no need to copy this data around for people who do not work with > Bazaar directly. The original branch is a Bazaar branch here, so that's not true. You can only work with any cloned branch if the matching bzr/ branch is also around. If it isn't then you won't be able to find the original commit. hg-git already does something similar by putting a --HG-- line followed by hg-git specific metadata in the commit message when it pushes into Git. I'd like to find a place to put this data that's not as intruisive for users. Cheers, Jelmer
Attachment:
signature.asc
Description: This is a digitally signed message part