SVN/Tortoise - 标签生成

发布于 2024-07-09 08:08:17 字数 156 浏览 8 评论 0原文

在 Clearcase 中,我可以为给定的一组文件生成一个“标签”,并且始终返回到该标签以重新生成所有文件,就像生成标签时一样。

我如何在 Subversion 中执行此操作? 我正在使用 Tortoise 前端 [Windows] 进行 SVN,但我不知道如何完成此功能。

In Clearcase I can generate a "label" for a given set of files and always go back to that label to regenerate all the files as they were when I generated the label.

How do I do this in Subversion? I'm using the Tortoise front end [Windows] to SVN and I'm not sure how to accomplish this functionality.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(6

人疚 2024-07-16 08:08:17

事实上,在 SVN 中每次提交都会创建一个“标签”。 您可以随时返回到每个修订(提交)。

理论上,分支和标签之间没有区别。 只是分支会进一步开发并与不同开发人员的提交合并,而没有人应该提交标签。

标签通常会被赋予更详细的名称,例如“RC 1.5 - 看起来最终稳定的那一天”。

这就解释了为什么 Tortoise 中的“创建分支/标签”就是其中之一。

本质上 svn 只是将最后修订版的副本创建到另一个目录(例如标签)中。 该副本当然不是完整副本,而是正常的差异,因此具有连续的修订号。

In fact in SVN every commit creates a 'label'. You can go back to every revision (commit) at any moment.

There is no difference between a branch and a tag in theory. Just that a branch is developed further and merged with commits from different developers whereas noone should ever commit to a tag.

Tags are normally given a more verbose name such as 'RC 1.5 - the day when it finally seemed to be stable'.

That explains why 'Create branch/tag' in Tortoise are one.

And essentially svn just creates a copy of the last revision into another directory (e.g. tags). This copy is of course not a full copy but a normal diff, therefore the continuous revision numbers.

淡淡的优雅 2024-07-16 08:08:17

相当于 Subversion 中的标签的是“标签”(即在文件夹中创建分支以用于标记修订的特定目的)。 在存储库浏览器中,右键单击“复制到...”,然后选择一个新文件夹名称。

http://svnbook.red-bean.com/en/1.5/svn.branchmerge.tags.html< /a>

The equivalent to a label in subversion is a "tag" (i.e. creating a branch in a folder for the specific purpose of marking a revision). In the repo-browser, right click, "Copy to..." and then pick a new folder name.

http://svnbook.red-bean.com/en/1.5/svn.branchmerge.tags.html

心病无药医 2024-07-16 08:08:17

Tags 相当于 Subversion 中的标签。

标签是通过copy命令或在TortoiseSVNBranch/Tag菜单选项中创建的。

按照约定,tags 会复制到 Subversion 存储库中的 tags 路径。

顺便说一句,TortoiseSVN 帮助确实做得很好 - 日常使用指南非常有帮助。

Tags are the equivalent of labels in Subversion.

Tags are created via the copy command, or in the TortoiseSVN Branch/Tag menu option.

By convention, tags are copied to a tags path in the Subversion repository.

BTW, the TortoiseSVN help is really well done - the Daily Use Guide is very helpful.

淡写薰衣草的香 2024-07-16 08:08:17

你可以通过两种方式做到这一点。

  1. 提交文件的当前状态,现在您始终可以恢复到此版本并恢复文件的状态

  2. 使用当前文件创建一个新标签,并继续在主干中工作。

You could do this two ways.

  1. Commit the current state of files, now you can always revert to this revision and get that state of your files back

  2. Create a new tag with your current files, and continue working in the trunk.

冰火雁神 2024-07-16 08:08:17

使用 svn copy 并在标签文件夹中创建一个副本。 这比其他任何东西都更惯例,但大多数存储库都会有名为 trunk、tags 和branch 的文件夹。

不用担心创建额外的副本 - 它并不是真正复制所有这些文件 -
复制品在颠覆方面是廉价的。

例如:

svn copy /trunk/foo /tags/foo-1.0

Use svn copy and create a copy in the tags folder. This is more convention than anything else, but most repositories will have folders called trunk, tags, and branches.

Don't worry about creating extra copies - it's not really duplicating all those files --
copies are cheap in subversion.

For example:

svn copy /trunk/foo /tags/foo-1.0
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文