Search code examples
atlassian-sourcetree

How to switch to other branch in Source Tree to commit the code?


Recently I have installed Source Tree in my windows machine. How can I use the source tree for commit, merge of code to central repository?? And also how can I switch the branches ?? Can any one kindly provide me the links on how to overcome this??


Solution

  • Hi I'm also relatively new but I can give you basic help.

    1. To switch to another branch use "Checkout". Just click on your branch and then on the button "checkout" at the top.

    UPDATE 12.01.2016:

    The bold line is the current branch.

    You can also just double click a branch to use checkout.


    1. Your first answer I think depends on the repository you use (like github or bitbucket). Maybe the "Show hosted repository"-Button can help you (Left panel, bottom, right button = database with cog)

    And here some helpful links:

    Easy Git Guide

    Git-flow - Git branching model

    Tips on branching with sourcetree