5

I'm using git-tfs to clone a TFS repository, something I've been able to do successfully in the past. But with the current version when I run the command, like this...

git tfs clone http://NameOfOurTfsServer:8080/ $/NameOfMyProject -d

...I get an error code 128, e.g.:

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> Sep.Git.Tfs.Core.GitCommandException: Command exited with error code: 128 at Sep.Git.Tfs.Core.GitHelpers.Close(Process process) in c:\Users\matt\dev\github\git-tfs\GitTfs\Core\GitHelpers.cs:line 205 at Sep.Git.Tfs.Core.GitHelpers.<>c__DisplayClass8.<CommandOutputPipe>b__7() in c:\Users\matt\dev\github\git-tfs\GitTfs\Core\GitHelpers.cs:line 59 [etc.]

This is on git-tfs 14.0. I've tried several previous versions of git-tfs, but I get the same or similar errors on each one.

Has anyone run into this? Do you know a fix?

Ryan Lundy
  • 204,559
  • 37
  • 180
  • 211
  • I ended up switching to git-tf, which has steadily improved and does everything I need (when I'm stuck in a TFS shop). – Ryan Lundy Apr 17 '13 at 05:37
  • I saw this a few days ago cloning a very large repo (took over 48 hours to get everything) with git-tfs 0.17. I was running the following: `git tfs clone --rebase` Several times it bombed out with error 128. The first few times I just ran the same command again and it picked up where it left off. Later I switched to `git tfs fetch` which seemed to be more reliable for some reason (though it was almost done by then anyway). – Bender Apr 17 '13 at 02:59

2 Answers2

0

I have had issues like this, especially when the TFS server drops the connection. My workaround has been to delete the folder and run the same command again.

You may try quick-clone instead of clone, since it will finish faster. I am assuming that you don't need the full history.

Ryan Gates
  • 4,501
  • 6
  • 50
  • 90
  • 2
    If that's due to the fact that the tfs Server drop the connection during a long clone, you could test, instead of doing a new clone to do: git tfs cleanup and then git tfs fetch (to continue the clone...) – Philippe Jan 31 '13 at 11:58
0

That's probably too late, but for future reference it's important: Go to the Windows Credentials and remove all the credentials bound to TFS Git. It worked for me.

anc
  • 106
  • 4
  • 18