On Tue, Sep 08, 2009 at 06:10:05AM -0400, Matt McClure 
<matthewlmccl...@gmail.com> wrote:
> What is the recipe using the marks options to:
> 
> 1. Do an initial export from one VCS;
> 2. Import it to another VCS;
> 3. Do an incremental export from the first VCS;
> 4. Import the incremental changes to the second VCS?

Here is an example.

You have a git repo with 2 commits,
6ea71fe7d36cf5b81c2100d97a822ecf0bc04746 and
14b772a0d7cb983ab0c13d672ea89192c460d070.

When you use git-fast-export, it will produce something like:

----
commit refs/heads/master
mark :1
data X
first commit

commit refs/heads/master
mark :2
data Y
second commit
from :1
----

So in the exporter side you store the :1 <->
6ea71fe7d36cf5b81c2100d97a822ecf0bc04746 and :2
<->14b772a0d7cb983ab0c13d672ea89192c460d070 mapping.

Now if you create a third commit in git, let's say
e1f8f0cfbef594edd12aba13df8ec53d401ce944, then git-fast-export will
produce:

----
commit refs/heads/master
mark :3
data Z
third commit
from :2
----

And the "from :2" line is because
14b772a0d7cb983ab0c13d672ea89192c460d070 is a parent of
e1f8f0cfbef594edd12aba13df8ec53d401ce944, and from the marks file it
knows that 14b772a0d7cb983ab0c13d672ea89192c460d070 should be mapped to
:2.

It's the same on the importer side, just when you do an incremental
import, you will need the marks file to know that :2 means for example
"r2" in bzr.

HTH.

Attachment: pgpWIlH7lyV0M.pgp
Description: PGP signature

_______________________________________________
Mailing list: https://launchpad.net/~vcs-fast-import-devs
Post to     : vcs-fast-import-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~vcs-fast-import-devs
More help   : https://help.launchpad.net/ListHelp

Reply via email to