git-分支还是标签? [英] Git - branch or tag?

查看:114
本文介绍了git-分支还是标签?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个使用python 2.7开发的API.我有一些开发人员已经在使用它.我想将此API迁移到python 3.4. 我将不再支持python 2.7 API.

I have a API that was developed using python 2.7. I have some developers that are already using it. I would like to migrate this API to python 3.4. I will not give support for the python 2.7 API anymore.

我的代码存储在位存储桶中.最佳策略是什么? 只需创建一个简单的分支,例如"python3.4"?

My code is stored in bit bucket. What is the best strategy? Just make a simple branch, e.g., "python3.4"?

在master分支(python 2.7)上创建标签并启动新分支(python 3.4)?

Make a tag on the master branch (python 2.7) and start a new branch (python 3.4)?

推荐答案

是的,分支是正确的.您可能要修复Python 2分支中的错误,因此它应该是分支,而不是标签.标签用于发布.

Yes, branching is correct. It is possible that you will want to fix a bug in the Python 2 branch, so it should be a branch, and not a tag. Tags are for releases.

我将命名为Python 2分支python2,并将其命名为Python 3分支master.这样,更明显的是哪个分支处于活动状态.

I would name the Python 2 branch python2 and name the Python 3 branch master. This way, it is more obvious which branch is active.

这篇关于git-分支还是标签?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆