标记源代码的目的?
软件版本中标记的目的是什么?
谢谢
What is the purpose of tagging in a software release?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
软件版本中标记的目的是什么?
谢谢
What is the purpose of tagging in a software release?
Thanks
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(4)
这是一个时间点标记。
例如,发布给其他人(生产、开源)的软件通常会被赋予一个版本号。
IE。 MongoDB 1.6.5 出来了。我猜这个被标记为“/tags/mongodb_1.6.5”
这样,任何时候有人想确切地知道 mongodb 1.6.5 版本中的源代码是什么样的,他们可以只查看标签,而不是查看提交日志,这可能……很……长……阅读所有这些日志消息会很痛苦。
-丹尼尔
This is a point in time marker.
For example, software released to other people (production, open source) is often given a version number.
IE. MongoDB 1.6.5 came out. This I guess be tagged "/tags/mongodb_1.6.5"
This way, any time someone wanted to know EXACTLY what the source code looked like at release mongodb 1.6.5 they could just look though the tags, instead of the commit log which might be ... very... long.. reading all of those log messages would be a pain.
-daniel
在我的公司,我们用它来表示给定的修订在某种程度上是特殊的(当然,我们使用 git,但大多数标记的目的是相同的)。我们将其用于以下用途:
In my company we use it to signify that the given revision is special in some way (granted, we use git but mostly the purpose of tagging is the same). We use it for the following:
这样您就可以保留该版本发布时的源代码副本。
示例:
您致力于项目,并将更改提交到主干。当您发布时,您会在准备就绪时为主干创建一个标签,并且不再需要更改代码。
然后,一旦发布正式发布,您就可以继续向主干添加新功能和错误修复。
然后您会收到一份错误报告,需要在 1.1 版本中修复。
现在问题来了。您可能在发布后已经修复了主干中的错误,但您不想发布该代码,因为它具有可能尚未准备好的新功能。
那么您现在可以做什么,因为您在 1.0 标签中拥有发布 1.0 时的代码副本。您将分支标签,应用错误修复(或者可能将修复从主干合并到分支中),然后您可以将其发布为 1.1。
然后,您可以创建 1.1 标签,并根据需要多次重复该过程。
It's so you can keep a copy of the source as it was when that version was released.
Example:
You work on your project, committing your changes to trunk. When you release, you make a tag of the trunk just as you're ready and there are no more code changes.
Then once the release is out there in the wild, you continue adding new features and bug fixes to the trunk.
Then you get a bug report, that needs to be fixed in a 1.1 release.
Now here's the problem. You may have already fixed the bug in your trunk after releasing, but you don't want to release that code because it has new features that may not be ready yet.
So what you can do now, since you have a copy of the code as it was when you released 1.0 in your 1.0 tag. You will branch the tag, apply the bug fix (or maybe merge the fix from the trunk into the branch) and you can release that as your 1.1.
You could then make a tag of 1.1 and repeat the process as many times as you need to.
标签是一组修订版(或在 svn 中的修订版)的符号名称。它可能对应于版本号 - 这是一个包含许多部分的标识符,旨在传达它在树中的位置、不同版本的更改程度以及它可能与其他应用程序或库的兼容性。
a tag is a symbolic name for a set of revisions (or in svn a revision). It may correspond to a version number - which is an identifier with many parts meant to convey where in the tree it is, the degree of change from a different version and it's likely compatibility with other applications or libraries.