Skip to content

Latest commit

 

History

History
69 lines (43 loc) · 648 Bytes

Git 分支管理.md

File metadata and controls

69 lines (43 loc) · 648 Bytes

添加分支

git branch

git branch test1.0

切换分支

git checkout

git checkout test1.0

添加分支并切换

git checkout -b

git checkout -b test1.0

查看所有分支

git branch

$ git branch
* master
  test1.0

删除分支

git branch -d

git branch -d test1.0

合并分支

合并到主干。

git merge

git merge test1.0

提交分支

git push origin

git push origin test1.0

查看分支差异

git diff <source_branch> <target_branch>

git diff master test1.0