首页 > 其他 > 详细

git-工作流

时间:2021-04-09 16:26:49      阅读:22      评论:0      收藏:0      [点我收藏+]

1 集中式

2 功能式    我们公司目前使用      master (主 用于部署线上)  dev(开发/测试)  

3 pull request      工作流  gitlab演示   setting->repository->protocted

4 gitflow 工作流  大型项目使用

 

master

hotfix  直接从master 拉  然后也是直接上传master

 release  层

develop

 

 

feature->a

 feature->b

gitlab建好项目 设置开发者权限 

git clone  

git checkout -b develop

修改代码  

git add --all  

git commit -m "备注"

git push origin develop

//

开发者1

git clone 

git checkout develop

git checkout -b  sanmao develop

修改代码

git add 

git commit -m 

git checkout develop

git pull origin develop

git merge sanmao

git push

git branch -d sanmao  删除分支

 

 

git checkout  -b release-0.1  develop

git add     git commit -m      git  push origin release-0.1

 

git checkout master

git  merge release-0.1

git push

 

git checkout develop

git merge release-0.1

 

git  tag -a 0.1 -m  ‘0.1 initial pubic release‘  master

git push --tags

 

 

//修改bug 

git checkout -b   issue-#001  master

git add   git commit -m 

gti push  origin  isseu-#-001

git checkout master 

git merge  issue-#001

git push

 

 

git  checkout develop

gti merge issue-#001

git push origin develop

 

git-工作流

原文:https://www.cnblogs.com/fly-fly-fly-fly/p/14636751.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!