Source Control provider not switching automatically in VS2012? RRS feed

  • Question

  • Hi!

    In all previous versions of VS, the source control provider switched automatically when I opened a project.

    Now, with VS2012, when I last used for instance Ankh SVN or VSS 6d and open a TFS2012 project, it just complains that the project either isn't under SC anymore, or is using "another provider" that the configured one. To get "back", I switch to TFS2012 and I have to rebind all projects.

    Is there some hidden option to "re-enable" automatic SC detection / switching, or is the feature just killed?


    Lars-Erik MCPD ASP.NET 2.0

    Tuesday, October 23, 2012 11:18 AM

All replies

  • As I know, we should change the VS soruce control plug-in manually in VS options, and select one source control plug-in for current project, then VS can open and load the specific SC plug-in for the project. Do not know how to let previous version VS do it automatically, I checked VS 2010 and 2008, they were the same with VS 2012.

    Below is my test screen, I change the VS 2010 and 2012 SC plug-in to AnkhSVN, and then connect to one TFS server to open its SC in TFS, but VS show the current SC plug-in is not TFS so cannot open the SC:

    Could you please share the steps how to operate the project and can allow previous VS to do it automatically? Thanks.

    Bob Bao [MSFT]
    MSDN Community Support | Feedback to us

    Wednesday, October 24, 2012 3:01 AM
  • Hi!

    Thanks, but I know perfectly well how to switch SCC providers. ;)
    I'm also aware I can close the solution, switch, reopen and then not have to rebind.
    Thing is, before I didn't have to do that.

    In VS solution files there's a section called GlobalSection with the SCC provider as a "function parameter". For instance "GlobalSection(SubversionSCC) = preSolution" or "GlobalSection(TeamFoundationVersionControl) = preSolution".

    I imagine that those are what earlier versions of VS use to pick the provider automatically when you open the solution.

    They are still there in VS2012 solution files, but as stated, VS2012 doesn't switch when opening the solution.

    Lars-Erik MCPD ASP.NET 2.0

    Wednesday, October 24, 2012 6:57 AM
  • Lars-Eric,

    I ran into a similar issue (I think).

    This was at the top of my solution:

    GlobalSection(TeamFoundationVersionControl) = preSolution
    SccNumberOfProjects = 2

    But I noticed this at the end of my solution:

    GlobalSection(SubversionScc) = preSolution
    Svn-Managed = True
    Manager = AnkhSVN - Subversion Support for Visual Studio

    I removed this from the end and things seem to work better for me now.

    Dunno if this helps you or not.

    John Michael Hauck

    Monday, November 26, 2012 3:50 PM