git 命令合並分支


https://www.cnblogs.com/xieyang-yang/p/10767330.html

 

需求:將develop合並到master分支

1.查看當前分支(當前分支可以直接查看或者命令查看)

git branch或者命令git status

*代表當前分支

 

2.切換分支到master

git checkout mater

3.將代碼更新到最新版本

git pull

4.在master分支上,將develop分支合並到master上面

git merge develop

如果不行,使用命令

git merge develop --allow-unrelated-histories

5.添加到緩存

 

git add .

6.提交到本地分支

git commit -m '20190424'

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM