开发者

How do I remove TFS connections from a Visual Studio 2010 C# project/solution?

I have been given the full source code to work on locally (C#.NET/XAML/Visual Studio 2010), but I do 开发者_JS百科not have access to TFS.

Every time I open the solution, it always asks for TFS which I have to cancel every time, but the code is now developed locally from here on out and I will not have access.

How do I effectively "disconnect" TFS from this build?


You can either choose to work offline, or unbind the projects:

File->Source Control->Change Source Control


File>Source Control>Change Source Control...>Unbind

Beaten to it...


If solution is already unbound (which happens sometimes), you can simply open the solution file, or the project file in notepad, and delete information regarding connecting to TFS.

In solution files (.sln files) for example, you might see information like this:

GlobalSection(TeamFoundationVersionControl) = preSolution
    SccNumberOfProjects = 4
    SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C}
    SccTeamFoundationServer = https://nemati.visualstudio.com/defaultcollection
    SccLocalPath0 = .
    SccProjectUniqueName1 = ..\\Framework\\Framework\\Framework.csproj
    SccProjectName1 = ../Framework/Framework
    SccLocalPath1 = ..\\Framework\\Framework
    SccProjectUniqueName2 = Website\\Phis.csproj
    SccProjectName2 = Website
    SccLocalPath2 = Website
    SccProjectUniqueName3 = Tests\\Tests.csproj
    SccProjectName3 = Tests
    SccLocalPath3 = Tests
EndGlobalSection

Just read it, and you'll understand what it says. Very simple, self-descriptive and self-explanatory. Just delete this section and reopen your solution.


The best way I found was to go Tools > Options Then, under the left hand menu select "Source Control".

You should see a "Current source control plug-in:" dropdown menu on the right hand side. Select "None" and please do this while no projects are open.

Doing it this way makes it easy if you ever wanted to learn TFS.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜