Git horror
I am trying to do something that I think is very simple, clone an SVN repository to a local Git repository.
Unfortunately, just about anything that I do end up in one error or another.
E:\rt\rt>git --version
git version 1.6.4.msysgit.0E:\rt\rt>cd..
E:\rt>git svn clone https://rhino-tools.svn.sourceforge.net/svnroot/rhino-tools rt.git
Initialized empty Git repository in e:/rt/rt.git/.git/
RA layer request failed: PROPFIND request failed on '/svnroot/rhino-tools': PROP
FIND of '/svnroot/rhino-tools': could not connect to server (https://rhino-tools
.svn.sourceforge.net) at C:\Program Files\Git/libexec/git-core/git-svn line 1699E:\rt>svn list https://rhino-tools.svn.sourceforge.net/svnroot/rhino-tools
BDSLiB/
branches/
contrib/
deprecated/
experiments/
tags/
trunk/
I even tried doing this on my Mac, which worked, but only until revision 2085, after which it refuses to do anything.
I know that I haven’t done much with Git so far, but I don’t think that I am doing something that wrong.
Comments
I've never tried with a huge repository. I've seen it hiccup on certain repositories as well, it could be the "-" in rhino-tools.
The windows version that is.......not git itself.
I had similar problems. I think it's just the "svn" functionality of git possibly being a bit flakey, or maybe strange things we had done to our svn branches back in the day.
So instead I looked at pulling a revision range
"git svn clone -r 3000:HEAD http://mysvn d:\some\git\dir"
I'd ideally like to get all the revisions, but in our case I don't think the earlier ones (-3000 goes way, way back) are too important.
Also I did find one time the above would fail, and another it would mysteriously work. No idea why it would get stuck. I tended to run it then not touch my pc in fear it might get stuck!
Once you do get Git up and running it's nice though. I'm trying to get it to work in a Windows only environment which isn't easy.
Also another thought. If you have access to a Linux VM, it may be worth trying Git from the terminal, rather than using msysgit in Windows.
Or maybe try cygwin from Windows with Git installed (although if I remember correctly this is what I tried and it got stuck).
Msysgit's git-svn I'd sub par. This is not a git horror. This is an MSysGit horror. Git rocks :)
I had the same issues. Figured out in the end that repositories on the http(s) protocols don't work. Had to use svn protocol and it work like a charm.
I just updated my repo successfully with msysgit from:
rhino-tools.svn.sourceforge.net/.../rhino-tools
When I create a git mirror of an svn repo, this my usual workflow:
mkdir mirror
cd mirror
git init
git svn init -s --prefix=svn/ rhino-tools.svn.sourceforge.net/.../rhino-tools
git svn fetch
....wait a really really long time for big repos...like, days even...
git reset --hard svn/trunk
git push origin master
....create and push local branches based on my required svn branches
When I want to update with the latest svn commits, I return to the mirror folder and:
git svn fetch
...reset and push my local branches again
I have seen the error you've posted before - I've had it occasionally while obtaining the latest changes. Usually it is network related because when I try a few minutes later it all works ok.
All in all msysgit is working pretty sweet for me and my colleagues. git-svn isn't perfect, but as you can see from the number of svn mirrors I have at github, it must work well enough.
My comment has been mildly mangled there. There should be https:// prefixes on the rhino-tools urls.
r2085 was right around the time I had problems pulling your svn repo into git, and if you recall I needed to have you remove a problematic content file (r2093)
I am scratching my head right now trying for the life of me to remember what I did to get around that....which i will continue to do.
Now, if you want shortcuts here is just the trunk
github.com/chrisortman/rhino-tools/tree/master
You can clone that and then do your git svn init and fetch and skip A LOT of time.
If you go the short cut way this might be helpful
codeprairie.net/.../...th-the-castle-git-repo.aspx
The trick is to pull the svn branches from another repo into the same one you are going to have svn-fetch pulling to.
I didn't think mySysGit supported the git-svn functionality yet. I think you have to use Git from Cygwin, at least that's what works for me.
You can also clone from a specific revision with -r. I often just pull HEAD, or last few revisions I may want to diff, from svn repositories and use svn log to view history. If you intend to continue using svn as the master repository then this is real time saver.
huh. i didn't even know you could do that. maybe I will move my svn repos to git; this would make it easy.
I think i might have specified a revision to skip over the commits that were bad between 2085 and 2093....that seems to ring a bell anyway
Not that it solves your problem, but a clue is "RA layer request failed:".
From past misadventures in Subversion land, I'm intimately familiar with error messages preceded by that string, followed by utterly useless garbage that tells me nothing meaningful that I didn't already know.
To my mind, that error message is suggesting that the problem lies with the version of SVN libraries that the Git you have is linked against.
I think James L is onto something. I got very similar messages with an out-of-date TortoiseSvn one of my VMs had installed.
Comment preview