Create remote GIT branch with Visual Studio Online

13,728

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
Share:
13,728
adova
Author by

adova

Updated on June 14, 2022

Comments

  • adova
    adova almost 2 years

    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.

  • adova
    adova over 8 years
    Gawd - go figure i was looking in the "Branches" tab rather than the "Explorer" tab to create branches. thx!
  • adova
    adova over 8 years
    From VS, the Publish Branch option is Grey Out - need to explore why that is.
  • Eddie Chen - MSFT
    Eddie Chen - MSFT over 8 years
    "Publish Branch" button will be Gray Out as soon as the branch is published to remote repository once.
  • Tom McDonald
    Tom McDonald almost 7 years
    Step 3 is different In VS 2017. It now says "Push Branch" not "publish branch". It does the same thing, however, despite the wording change.