共享功能或不在git流? [英] sharing features or not in git flow?
问题描述
特征/账户
之类的特征分支可以由A和B共享以合作开发账户。 如果我们管理上面的功能分支:
问题1:是否建议在东西之间共享功能分支之间的东西?
还有另一种方法来管理功能分支,如下所示:
- stuff管理一个名为
特性/帐户视图
的分支stuff B管理一个名为
的分支feature /但是,如果我们管理像帐户视图这样的功能分支,那么您可以使用帐户控制器 和>
和 account-controller
,我们需要在做一些测试工作之前先合并这两个特性分支。而且看起来工作流程变得更加复杂。
问题2:哪个分支管理更好? 功能/帐户
或功能/帐户视图
功能/帐户控制器$ c
$ b $ div class =h2_lin>解决方案
是否建议在东西之间共享功能分支?
$ / b
是的,这就是配置:
通常,
功能/账户控制器
更实用,更接近配置管理:您的分支代表您需要配置的配置。
如果stuffA
和stuffB
在他们自己的Git仓库中,那么它就是一个组件方法,您可以使用一个分支来隔离在一组组件(文件组,这里stuffA
和stuffB
,你的配置)你需要开发和测试。In development, we often come across a scenario like this:
In a MVC web development, stuff A may mainly develop View, while stuff B may mainly develop Controller, then a feature branch like
feature/account
maybe shared by A and B to cooperate the development of account.If we manage feature branches like above:
Question 1: Is it recommended that sharing feature branches between stuffs between stuffs?
There's another way to manage feature branches, like this:
- stuff A manage a branch named
feature/account-view
- stuff B manage a branch named
feature/account-controller
However, If we manage feature branches like
account-view
andaccount-controller
, we need to merge these two feature branches first before doing some testing jobs. And it seems the workflow becomes more complicated.Question 2: Which branch management is better?
feature/account
orfeature/account-view
feature/account-controller
解决方案Is it recommended that sharing feature branches between stuffs?
Yes, that is what a configuration is:
Generally,
feature/account-controller
is more practical, and closer to a configuration management: your branch represents the configuration you need to work.
IfstuffA
andstuffB
are in their own Git repos, then it is a component approach, where you use one branch to isolate evolutions done on a set of components (group of files, herestuffA
andstuffB
, your config) you need to develop and test.这篇关于共享功能或不在git流?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!