Search code examples
cmdgit-tfs

Given tfs name is not correct URI and not found as a registered TFS instance


Using git-tfs, when I try and connect to my tfs server I get the error message:

Given tfs name is not correct URI and not found as a registered TFS instance

The command I'm using is:

git tfs clone "http://ip.add.re.ss:8080/tfs/Collection Name/" "$/Project Name" "C:\git"


Solution

  • Spaces cause issues when connecting. The way around it is:

    git tfs clone "http://ip.add.re.ss:8080/tfs/Collection%20Name/" $/"Project Name" "C:\git"

    i.e:

    1. For the collection, use %20 to replace spaces
    2. For the project, put the open quote after the $/ instead of before