Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How to Merge content from multiple branches into a single branch in source tree?

shouren dalvi May 13, 2013

I have 5 branches in sourcetree which has various files in it

for eg- blogs-b2,blogs-log,frontaccounting,crm,contentmanagement

I want to merge the contents of these branches into a single branch named Simplescripts.

1 answer

1 accepted

1 vote
Answer accepted
stevestreeting
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 13, 2013
  1. Create the Simplescripts branch if it doesn't already exist, anc check it out (there's an auto-checked box in the create branch dialog that will do that for you)
  2. Right click on one of your branches eg blogs-b2, select 'Merge' & confirm
  3. Repeat 2 for each of those other branches

If you have any conflicts after 2. you can resolve them by right-clicking the file, selecting Resolve Conflicts and picking an option, such as Resolve in External Merge Tool to interactively merge with a merge tool.

(Note, in git there's a type of merge called an 'octopus merge', where you can merge many branches into one at once. SourceTree can display octopus merges but doesn't let you create them right now - to be honest I think separate merges are tidier anyway ;))

shouren dalvi May 13, 2013

Thanks a lot!!

shouren dalvi May 13, 2013

Thanks a lot steve!..I tried it and it worked smoothly!!

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events