How to get rid of “The solution you are trying to open is bound to source control” message

∥☆過路亽.° 提交于 2019-11-28 21:05:48

问题


I have a Visual Studio solution files copied from a source controlled solution. I don't want it to be source controlled and when I open it I get the message: the solution you are trying to open is bound to source control

I deleted the .vssscc files but still get the message. How can I get rid of it?

Thanks.


回答1:


You need to clean the solution file (.sln) by removing the following GlobalSection:

GlobalSection(TeamFoundationVersionControl) = preSolution
    SccNumberOfProjects = 2
    SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C}
    SccTeamFoundationServer = http://example.com/tfs/defaultcollection
    SccLocalPath0 = .
    /// --- more solution specific stuff omitted --- ///
EndGlobalSection

and you need to remove the source control references from every single project file (.csproj for C# projects):

...
<SccProjectName>SAK</SccProjectName>
<SccLocalPath>SAK</SccLocalPath>
<SccAuxPath>SAK</SccAuxPath>
<SccProvider>SAK</SccProvider>
...


来源:https://stackoverflow.com/questions/21883129/how-to-get-rid-of-the-solution-you-are-trying-to-open-is-bound-to-source-contro

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!