git merge 命令的使用

我们把dev分支的工作成果合并到master分支上:

$ git merge dev
Updating d46f35e..b17d20e
Fast-forward
 readme.txt | 1 +
 1 file changed, 1 insertion(+)

 git merge 命令用于合并指定分支到当前分支。

若果合并后要删除不要的dev分支:

$ git branch -d dev
Deleted branch bbranch (was 78aae58).

详见:

Git官网: 

https://git-scm.com/docs/git-merge

https://git-scm.com/book/zh/v2/Git-%E5%88%86%E6%94%AF-%E5%88%86%E6%94%AF%E7%9A%84%E6%96%B0%E5%BB%BA%E4%B8%8E%E5%90%88%E5%B9%B6

廖雪峰老师:

https://www.liaoxuefeng.com/wiki/896043488029600/900003767775424

原文地址:https://www.cnblogs.com/taohuaya/p/10860945.html