Git merge two local branches

user3127896 picture user3127896 · Jul 31, 2014 · Viewed 193.4k times · Source

I have branch Master, branchA and branchB. Now I'm working in the branchA and I need to merge branchA with branchB and proceed my work in the branchA. All files are comitted in the branchA and branchB.

What's the fast way to implement it?

Answer

Abimaran Kugathasan picture Abimaran Kugathasan · Jul 31, 2014

If I understood your question, you want to merge branchB into branchA. To do so, first checkout branchA like below,

git checkout branchA

Then execute the below command to merge branchB into branchA:

git merge branchB