如何与 TeamCity 进行历史性持续集成?
我刚刚开始使用 CI,我正在尝试在我的代码库上创建一些指标。有没有办法让 TeamCity 从一开始就对 SVN 存储库中的源代码的每个版本运行构建?我只能找到如何从现在开始构建,而不是从 r1 开始。
我还想知道您是否可以构建每个修订版本,而不仅仅是每个投票周期一次。
I'm just getting started with CI, and I'm trying to create some metrics on my codebase. Is there a way to get TeamCity to run the build on each revision of my source in my SVN repository from the beginning? I can only find how to do builds from now on, not from r1.
I'd also like to know if you can build every revision, not just once every polling period.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
好的,这是一种方法(不是很简单,但至少可以完成):
例如,如果您的源代码位于 subversion 中,则可以在脚本中使用 svnadmin dump 将修订版逐个修订版传输到新存储库中。
如果您以适当的时间间隔执行此操作,并让 teamcity 监听新存储库中的更改,teamcity 应该为每个修订版触发新的构建。
考虑到这一点,另一个没有转储的理论解决方案是:
我还没有测试过这些,但是嘿,可能会出什么问题呢? ;-)
Ok, here's a way to do it (not very straightforward but it could get it done at least):
If you for instance have your source code in subversion, you could use svnadmin dump in a script to transfer revision by revision into a new repository.
If you do this with an appropriate interval and let teamcity listen to changes in the new repo teamcity should trigger a new build for each revision.
Thinking of it, another theoretical solution without dumps would be to:
I haven't tested any of these but hey, what could possibly go wrong? ;-)