Change remote HEAD branch in git hosted on Visual Studio online

When people clone this particular online reconstruction of a visual studio, instead of getting the expected master branch, they get a branch called initial .

I would like the branch named master to be the default branch that gets the checkbox when cloning the repository.

In fact, when I run git branch -a I get the following result:

 remotes/origin/HEAD -> origin/initial remotes/origin/initial remotes/origin/master 

Which basically confirms that HEAD points to the start.

Also note that I do not have direct access to the remote file system (since it is hosted on Visual Studio online).

In github.com, this is possible through the web portal, but I did not find a similar option in the online studio.

How can I change the remote repository to the next state?

 remotes/origin/HEAD -> origin/master 
+5
source share
1 answer

In Web Access, navigate to the repository in question. From the repository drop-down list, select "Manage repositories ...":

Manage repositories

On the left side of the repository management page, you can expand the repository to see the branches. Select the branch you want to make the default branch, right-click and select "Set as default branch."

Set as default branch

+7
source

Source: https://habr.com/ru/post/1203889/


All Articles