TFS 中的孤立分支

发布于 2024-07-13 07:04:58 字数 147 浏览 7 评论 0原文

我们在 TFS 中有一个主干,每个人都在工作,直到我们需要分支为止。 我们的上一个项目是一个需要分支的大型功能。 现在开发已经完成,更改已合并回主干。 开发分支应该发生什么?

我应该删除它吗? 以某种方式将其标记为只读? 隐形和锁定怎么样?

We have a trunk in TFS that everyone works off until we have a need to branch. Our last project was a large feature that required a branch. Now that the development has been completed and the changes have been merged back into the trunk. What should happen to the development branch?

Should I delete it? Mark it as read-only somehow? What about cloaking and locking?

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

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

发布评论

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

评论(3

累赘 2024-07-20 07:04:58

可以将分支设置为只读。 您只需从适当的组中删除签入/签出权限即可。 请注意,乍一看它看起来没有任何不同,但是当您尝试签出文件时,您将被阻止。

我总是最终删除分支。 它已被“删除”,但没有什么可以阻止您取消删除它(这与销毁不同)或回顾代码。 除非你努力摧毁它,否则它实际上不会去任何地方。

此外,如果您有像 Team Foundation Sidekicks 这样的好工具,您仍然可以看到所有分支历史记录,即使它已被删除。

正如 @Ray 所说,您可以将其保留,但如果您在十几个分支中这样做,事情就会变得有点难以管理。 如果分支已经死了,并且您已将代码合并到主线中,那么除了“以防万一”之外,您还有什么目的保留它吗?

如果是这样,只需删除它并仅在确实需要时重新挖掘它。

You can make a branch read-only. You just need to remove the check-in/check-out permissions from the appropriate groups. Note that it doesn't look any different on first blush, but when you attempt to check out a file, you'll be prevented.

I always end up deleting the branch. It's "deleted" but there's nothing preventing you from undeleting it (which is different that destroying) or looking back at the code. It doesn't actually go anywhere unless you go through the effort of destroying it.

In addition, if you have a nice tool like Team Foundation Sidekicks, you can still see all of the branching history, even if it's been deleted.

You can, as @Ray says, just leave it, but if you do that over the course of a dozen or so branches, things become a bit unwieldy to manage. If the branch is dead, and you've merged the code into mainline, do you have any purpose for keeping it around aside from "just-in-case."

If so, just delete it and dig back through it only if you really have to.

自我难过 2024-07-20 07:04:58

别管它吧。 :) 您可以删除该分支,但它仍将保留在存储库中。 这确实是您和您的团队可以做出的遵循源代码控制指南的决定。

顺便说一句,TFS 中没有只读选项,您只能保留它、删除它或运行 TFS destroy 命令来永久删除分支。

Just leave it. :) You can delete the branch but it will still remain in the repository. It really is a decision that you and your team can make to follow your source control guidelines.

On a side note, there is no read-only option in TFS, you can only leave it, delete it or run the TFS destroy command to permanently remove the branch.

很酷不放纵 2024-07-20 07:04:58

有读取访问控制权限。 如果您将贡献者设置为“拒绝”,它应该覆盖任何“未设置”或“允许”权限。 您可以通过右键单击文件夹并进入“高级”|“源代码管理资源管理器”来设置它。 安全...

There is a Read access control permission. If you set Contributors to "Deny", it should override any "Not Set" or "Allow" permissions. You can set it in Source Control Explorer by right-clicking on the folder and going into Advanced | Security...

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