1. 首先你要有两个或者多个代码仓库,比如A 和B两个文件夹,下面放了两个工程的代码,现在假如你的需求是把A里面的代码合并到B仓库
2. cd 到 B目录,执行 `git remote add other ../A/`
2. 继续执行 `git fetch other`
3.继续执行`git checkout -b A other/master`
4. 继续执行 `git checkout master `
5. 继续执行 `git merge A`
6.最后就可以push了
参照 https://blog.youkuaiyun.com/gouboft/article/details/8450696
参照 https://my.oschina.net/u/2007323/blog/1860305/
这个git使用命令合并代码还是有不太友好啊哈哈哈,需要多练习