与 Subversion 和 CVS 持续集成

发布于 2025-01-02 19:44:07 字数 1482 浏览 1 评论 0原文

在我目前从事的项目中,我们同时使用 Subversion 和 CVS。开发人员通常会开发代码并签入 CVS/Subversion。

当编码完成并且所有内容都已签入后,我们使用测试标签标记存储库,并使用使用 TEST 标签签出的代码进行正式测试。

我们不使用 trunc 进行标记,而是使用以前的标记:

- Tag RELEASE.0.1 as PROJ-ABC-LIVE.1.3
- Tag revision 12 as PROJ-ABC-LIVE.1.3 (new changes not part of RELEASE.0.1)

上面的内容确保只有来自最后一个版本 + 新修订版本的文件才使用新版本标签进行标记,从而排除任何未经测试的内容。

当测试完成并且对代码进行任何其他更改(作为测试的结果)时,代码将被标记为 LIVE 标签。 LIVE 标签是签出并部署到 LIVE 服务器上的代码。

在任何时候,存储库的截断都可以包含人们所做的任意数量的更改。在某些情况下,人们会签入“正在进行”且不完整的代码更改。对于某人来说,办理入住手续并去度两周的假期是完全正常的。

作为示例,这里是我们存储库中修订文件的示例状态。

1.4
1.5
1.6 PROJ-ABC-TEST.0.1
1.7 
1.8 PROJ-ABC-TEST.0.2
1.9 PROJ-ABC-LIVE.1.3
1.10
1.11

当我们发布版本时,我们将检查带有 PROJ-ABC-LIVE.1.3 标签的所有内容,并将其作为正式版本交付。修订版 1.10 和 1.11 不包括在内,因为这些是当前 trunc 中的新更改。

我很难理解在这种情况下如何使用像 Jenkins 或 Hudson 这样的东西。如果我们真的引入它,它到底会给我们带来什么好处?

如果我们真的引入它,不是每次都会构建相同的版本吗?我们只使用标签构建,所以如果我引入 Jenkins/Hudson,我必须将其配置为按标签构建。它不是每次运行时都会构建 PROJ-ABC-LIVE.1.3 吗?除非可以使用最新的标签进行构建。

我见过的关于如何使用 CI 的大多数示例是,每次存储库中发生更改(提交)时,大多数人都会从 trunc 进行构建。如果人们签入不完整的工件,这将如何工作?如果 trunc 永远不稳定(这并不是故意的),我真的不明白从 TRUNC 构建有什么好处。

也许我对 CM 不是很了解,但是如何发布由 Trunc 构建的东西呢?我想我的问题是

  • 在 trunc 包含不完整工件的情况下如何使用 CI
  • 如果标签用于所有交付,CI 环境是否不会在每次运行时重新构建相同的代码?标记的快照永远不会改变——因此 CI 环境没有任何作用?
  • 如果我们不从 trunc 构建,CI 有用吗?从 Trunc 构建到底有什么好处?
  • 我认为它可能对我们有用的唯一方法是它能够检测是否已应用新的 LIVE 标签并从中构建。这可能吗?
  • 还有其他我错过的可能对我们有益的场景吗?

谢谢

In the project i currently work on, we use both Subversion and CVS. Developers would usually develop code and check in to CVS/Subversion.

When coding is complete and everything has been checked in we tag the repository using a test label and carry out formal testing using code checked out using the TEST label.

We don't tag using the trunc instead we use the previous tag:

- Tag RELEASE.0.1 as PROJ-ABC-LIVE.1.3
- Tag revision 12 as PROJ-ABC-LIVE.1.3 (new changes not part of RELEASE.0.1)

The above ensures that only files from the last release + the new revisions are tagged with the new release label and thus excluding anything that has not been tested.

When testing is complete and any additional changes are made to the code (as a result of testing) the code is then tagged with a LIVE tag. The LIVE tag is the code that is checked out and deployed on to the LIVE server.

At any one time, the trunc of the repository can include any number of changes that people have made. In some cases, people would check in code changes that are 'In progress' and are incomplete. It is perfectly normal for someone to check in something and go on a two week holiday.

As an example here is a sample status of a revision file on our repository

1.4
1.5
1.6 PROJ-ABC-TEST.0.1
1.7 
1.8 PROJ-ABC-TEST.0.2
1.9 PROJ-ABC-LIVE.1.3
1.10
1.11

When we make a release we would check out everything with the tag PROJ-ABC-LIVE.1.3 and deliver that as a formal release. Revisions 1.10 and 1.11 are not included as those are new changes currently in trunc.

I am having a hard time to understand how something like Jenkins or Hudson would be used in this scenario. What exactly would it do for us if we do introduce it.

If we do introduce it, would it not just build the same release every time? We only build using tags so if i introduce Jenkins/Hudson i would have to configure it to build by tag. Would it not just build PROJ-ABC-LIVE.1.3 everytime it runs? Unless it is possible to build using the latest tag.

Most of the examples i have seen of how CI is used is that most people build from trunc everytime there is a change (commit) in the repository. How would this work if people check-in incomplete artifacts? I don't really see what is the benefit of building from TRUNC if the trunc is never stable (Which it is not meant to be).

Maybe i am not very knowledgeable about CM but how is it possible to release something that is built from Trunc? I guess my questions are

  • How is CI used in situations where the trunc includes incomplete artifacts
  • If tags are used for all deliveries wouldn't the CI environment be re-building the same code everytime it runs? Tagged snapshots never change - and thus the CI environment serves no purpose?
  • Is CI useful if we don't build from trunc? What exactly is the benefit of building from Trunc?
  • The only way i think it might be usable to us if it is capable of detecting if a new LIVE tag has been applied and build from that. Is this possible?
  • Are there any other scenarios where it could be beneficial to us that i have missed?

Thanks

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

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

发布评论

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

评论(1

南街九尾狐 2025-01-09 19:44:07

简短的答案(@JB 强烈暗示)是您根本没有使用 CI 流程 - 所以 CI 服务器不会对您有太大帮助。我强烈建议您的团队切换到 CI 流程。这是 Martin Fowler 撰写的开创性论文,介绍了其全部内容。祝你好运!

The short answer (as @JB is heavily hinting) is that you are not using a CI process at all - so CI server would not help you much. I would strongly recommend that your team switches to a CI process. Here is a seminal paper by Martin Fowler on what it's all about. Good luck!

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