Thread (17 messages) flat view 17 messages, 8 authors, 2016-06-15

Re: How to clone git repository with git-svn meta-data included?

From: Michael J Gruber <hidden>
Date: 2016-06-15 22:45:44

Grzegorz Kossakowski venit, vidit, dixit 07.12.2008 23:02:
Peter Harris pisze:
quoted
After the git clone, I do the following:
git svn init -s svn://repo/sitory
git svn rebase

No data is transferred[1], although 'git svn rebase' does spend a
minute or so reading the commit messages to rebuild its index.
I've tried this method with Cocoon repository
(http://jukka.zitting.name/git/?p=cocoon.git;a=summary) and got this error:

git clone git://jukka.zitting.name/cocoon.git
git svn init -s https://svn.eu.apache.org/repos/asf/cocoon/
git svn rebase
Unable to determine upstream SVN information from working tree history

git --version
git version 1.6.0.2
Could it be as simple as a missing "cd cocoon" between git clone and git
svn rebase? No, you probably did that.

But note that you did not follow Peter's instructions. The point is that
your clone creates "remotes/origin/trunk" whereas Peter's instructions
mirror the source, creating "remotes/trunk", which is what git svn needs
(unless you say "git svn init -s --prefix=origin/" or "git config
svn-remote.svn.fetch trunk:refs/trunk" etc.). The prefix solution should
be the best.

Michael

P.S.: Peter starts off a different layout (standard svn remotes, which
need special instructions to be cloned). Ordinary clone + git svn init
--prefix=origin/ should work fine for the cocoon layout.

P.P.S.: We can't test cocoon unless we have an account on the apache
server...
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help