Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Create remote GIT branch with Visual Studio Online

I am implementing a GIT repository in Visual Studio Online (and VS 2015 pro) and I am trying to implement a branching strategy that requires multiple remote branches. So, given that I start with "origin/master", I would like to branch off of that and have "origin/development".

I am guessing that I might be able to accomplish this with a command line, but is there a way to do this with VSO? Does this all even make sense, lol? I am obviously new to GIT.

like image 415
adova Avatar asked Nov 11 '15 01:11

adova


1 Answers

Yes, you can do this from VS and VSO.

From VS:

  1. Open “Branches” from Team Explorer.
  2. Right click on the project you’d like to branch and select “New local branch from…” to create a local branch.
  3. Right click on the new created branch and select “Publish Branch” to publish the local branch to your VSO Remote Repository.

    NOTE: In VS 2017+ it now says "Push Branch" instead of "Publish Branch"

From VSO:

  1. Open your project from VSO Web Portal.
  2. Click “Code” panel.
  3. Click branch dropdown and select New Branch to create a branch. enter image description here
like image 115
Eddie Chen - MSFT Avatar answered Oct 06 '22 05:10

Eddie Chen - MSFT