简体   繁体   中英

Visual Studio Git branches

I am new to GIT and GIT in VS, and struggling to create branch that will be visible to others.

What have I tried:

  1. Created local branch from remote/master as specified here
  2. Right click on branch shows disabled option "Publish branch"
  3. Everything I commit and sync is visible on master branch to other developers (but they don't see my new branch). This is especially annoying.

Please help me on how to create branch that will be visible to others and more important how to commit and sync changes to that branch only and master. Basically I expect to reproduce branches with the same behavior as in TFS source control (not GIT)

I am using: Visual Studio 2015 Community Edition with Visual Studio Team Services (was VS Online) git repository

If you want to publish the branch on remote origin , you have to push the branch not on master. To do that, check in the push windows the destination branch on the remote, and set the name of your branch.

It seems that by default, your mentioned branch is pushed to master.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM