bzr fast-import/fast-export what's the importance of marks file when dealing with multiple branches

Bailey, Darragh dbailey at hp.com
Wed Jul 13 15:26:25 UTC 2011


On 13/07/11 15:29, John Arbash Meinel wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On 7/13/2011 4:15 PM, Bailey, Darragh wrote:
>> While experimenting with using git-bzr-ng and import/export branches to
>> git/from bzr I'm wondering what is the importance of using the same
>> mark's files when handling related but unmerged branches from the same
>> repository?
>>
>> The example on
>> http://doc.bazaar.canonical.com/plugins/en/fastimport-plugin.html
>> indicates that one should do the following when exporting and import
>> related branches:
>>
>> bzr fast-export --export-marks=marks.bzr project.dev |
>>          GIT_DIR=project/.git git-fast-import --export-marks=marks.git
>>
>> bzr fast-export --import-marks=marks.bzr -b other project.other |
>>          GIT_DIR=project/.git git-fast-import --import-marks=marks.git
>>
>>
>> But nowhere can I find an indication of why this is important? Is this
>> just a performance improvement, or is there a repository history
>> integrity issue should it not be followed?
>>
> bzr fast-import generates new revision information for every commit. If
> you specify a marks file, it will re-use the imports from the other
> branch. If you don't, the branches won't share common revisions.
>
> John

Sounds like what I thought it might be. Although some testing with 
exporting from bzr to git seems to suggest that git doesn't need to use 
to same marks file to correctly associate common revisions, or it might 
just be luck with what I've tested.

Possibly something to do with how the sha-1's are calculated for each 
commit which means that git is managing to work out the history 
correctly anyway. Anyway I'll go poke the git devs on that. Thanks for 
the quick answer.

-- 
Darragh

"Nothing is foolproof to a sufficiently talented fool" - Unknown


More information about the bazaar mailing list