-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
wukeming
committed
Sep 29, 2022
1 parent
617af24
commit 22ecfb6
Showing
2 changed files
with
23 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Git分支策略 | ||
|
||
## Git 为什么会需要分支管理 | ||
|
||
分支主要作用是分割开发,当你在新签出的分支进行修改,优化,增加功能时,你提交的代码并不会影响到主干的代码,这样就可以保证我们的主分支一直保持可发布的状态。还有一个作用就是让我们的一个项目具有多套不同的代码。 | ||
与分支管理配合使用的还有tag,这个功能常被应用于发布关键版本的标记,也就是我们常常在开源软件中看到的v1.0.0、v2.0.2等。 | ||
|
||
## Git 的分支管理策略 | ||
|
||
一个完整的产品交付过程涉及到分支策略、团队的协作流程、基础设施建设等方方面面,高效的协作需要结合 `项目所处的阶段`、 `产品交付的频率`、 `团队成员的习惯和素养`等来制定适合自己团队的方案。 | ||
|
||
主流的分支策略有: | ||
|
||
- 主干开发,主干发布 | ||
- 主干开发,分支发布 | ||
- 分支开发,主干发布 | ||
- GitFlow | ||
- GitHub Flow | ||
- GitLab Flow | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters