Using Google Chrome, I go to our Microsoft Visual Studio Team Foundation Server (MS VS TFS) website, select a repository, and click on the "Clone" link/button in the upper right corner of the screen.
In the resulting "Clone repo" window, I click on the "Clone in Visual Studio" button.
In the resulting "Open Microsoft Visua…ndler Selector" window, I click on the "Open Microsoft Visual Studio Web Protocol Handler Selector" button.
Visual Studio (VS) opens with an "Azure DevOps Server" window, allowing for me to input the local path, which is the destination folder for the clone. I choose to keep the default/provided value for local path, which already has a folder name exactly the same as the repository name.
I click the "Connect" button and wait for the clone process to finish.
When it finally finishes, in the GIT repository and branch info in the bottom right corner of the screen, I can see that VS has "auto" checked out a (seemingly random?) branch instead of the branch marked as default in our MS VS TFS.
We have several old branches that we’re keeping for the moment, all of which begin with "DO_NOT_USE…", and for some reason (???) it selects one of those instead of the default branch.
So, how can I get VS to behave as expected and "auto" check out the default branch instead?
- Microsoft Visual Studio Enterprise 16.9.3
- Microsoft Visual Studio Team Foundation Server 15.117.27414.0
Source: Visual Studio Questions