I have always been able to create a project/solution and add it to source control and it will get added to TFS. In the last couple of months something has changed and when I create a new project/solution in Visual Studio 2015 Enterprise, it automatically uses git, even though the source control plugin is set to TFS. I have tried Tool>Options>Source Control and set the plugin back to TFS(VS resets this to git), closed Visual Studio, reopened and the plugin is still set to TFS until I add a project/solution to source control.
If I create a new project and add it to source control, I get no prompts, it immediately uses git(even though set to TFS). When I go back and look at the Source Control plugin it has been set to git by vs.
We don't use git, source control is TFS2010. Is there anyway of making VS it give me a choice of source control, or just assign it to only use TFS?
In the Team Explorer window, expand your team project, and then double-click Source Control. On the Source Control Explorer tab, click Not mapped. In the Map dialog box, in the Local folder box, browse to (or create) a local folder to act as the root folder for the team project, and then click Map.
A colleague of mine faced the same issue. He didn't check the "Add to Source Control" box when he initially create the project. Choosing "Add solution to source control" from the right click context menu in solution explorer adds the project to the local git repository. The solution was
Assuming you select Add to Source Control when you create projects. Try to connect to a TFS team project in Team Explorer before creating new projects.
I recently had this exact issue and it was to do with my connections. From within the Team Explorer tab, click on the green plug to go to connections. Click on the blue 'Manage Connections' link and choose 'Connect to Team Project'. Choose your TFS server if necessary, ensure that your new project is selected in the right hand pane, then click 'Connect'.
Make sure that the steps others have highlighted above are done (.git files and folders deleted and Source Control Plugin set to TFS) and you should then be able to just right click on the solution and choose 'Add Solution to Source Control' and you should then be able to bind to TFS.
I had this same issue after an update. I have to change the "plug in selection" to TFS, and then re connect to my TFS instance, for it to stop changing the default to GIT.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With