nirvdrum / svn2git

Ruby tool for importing existing svn projects into git.
MIT License
2.11k stars 443 forks source link

command failed: 2>&1 git svn fetch #69

Open borgified opened 12 years ago

borgified commented 12 years ago

i run this command: svn2git http://svn.alleg.net/svn/Allegiance --verbose

then i get this: (...) W: +empty_dir: trunk/x86 Use of uninitialized value $u in substitution (s///) at /usr/lib/git-core/git-svn line 2097. Use of uninitialized value $u in concatenation (.) or string at /usr/lib/git-core/git-svn line 2097. refs/remotes/svn/trunk: 'http://svn.alleg.net/svn/Allegiance' not found in ''

command failed: 2>&1 git svn fetch


http://svn.alleg.net/svn/Allegiance is in standard layout (trunk, branches, tags) at the root level of the repo so i did not use any other options when running git2svn

2096 my $u = (::cmt_metadata("$refname"))[0]; 2097 $u =~ s!^\Q$url\E(/|$)!! or die "$refname: '$url' not found in '$u'\n";

shockie commented 12 years ago

I had the same problem, happens when an error occurs (i missed some authors in the authors file) in the middle of the process. I solved it by removing the directory in where you executed svn2git, recreate it and execute it again. Still this isn't a solution and this issue needs to be fixed.

vBm commented 12 years ago

Confirmed. I have this problem as well. Hope it gets fixed soonish.

borgified commented 12 years ago

thx for the suggestion shockie. i just tried this out again and it worked this time... i issued the same command but on a different system... (still same ubuntu 12.04 though) so im not exactly sure what caused it to work...

borgified commented 12 years ago

ran it again successfully

guidupuy commented 12 years ago

@shockie's suggestion fixed it for me

samvdb commented 12 years ago

suggestion worked. removed the .git directory and ran it again with success

gregersrygg commented 12 years ago

I had the same problem. You don't need to delete the .git folder. Just fix an error in .git/config http://stackoverflow.com/a/4434188/44643

waldyrious commented 11 years ago

This issue seems to be a dupe of #50.

russellfeeed commented 10 years ago

thanks @gregersrygg and @shockie - you solutions worked

desbest commented 6 years ago

This error can happen if you miss out some authors in your authors file. Every author has to be mapped in the authors text file. If you run svn2git or svn2gitnet in verbose mode by adding --verbose to your command, it will show you what authors you haven't mapped.

rgoliveira commented 6 years ago

@gregersrygg's solution did the trick. Just opened up .git/config, removed the duped entries and ran svn2git --rebase to continue the process. Thanks!