合并全量代码:
如:需要将A分支的代码合并到B分支

操作步骤:

1、切换到A分支,pull更新代码 【git checkout A,git pull A】

2、切换到B分支,pull更新代码 【git checkout B,git pull B】

3、在A分支上右键选择merge into corrent 【git merge A】

4、提交B分支push 【git push B】
合并部分代码:
如:需要将A分支上的部分提交合并到B分支

操作步骤:

1、切换到A分支,pull更新代码 【git checkout A,git pull A】

2、切换到B分支,pull更新代码 【git checkout B,git pull B】

3、然后在Version Control—>Log中选择分支Branch(A分支),并选择符合的User、Date、Paths筛选需要合并的代码记录,在代码记录上右键选择Cherry-Pick进行合并。
在这里插入图片描述
4、提交B分支push 【git push B】

Logo

一站式 AI 云服务平台

更多推荐