在我们的办公室,我们使用自定义 Geckoboard显示有关 TeamCity 8 构建服务器当前构建状态的信息。
我们使用以下 REST 查询显示最近 checkin /更改:http://teamcity.internal.com:8080/httpAuth/app/rest/changes?project:项目名称&locator=count:10
我们还使用以下 REST 查询计算上次构建被破坏的时间:http://teamcity.internal.com:8080/httpAuth/app/rest/builds?locator=项目:项目名称
但是我们无法将两者联系起来。
换句话说:
- 用于最近的更改以确定 checkin 是否会导致构建损坏
- 最后一次构建被破坏确定谁进行了 checkin
最佳答案
我相信你想要类似下面的东西
http://teamcity.internal.com:8080/httpAuth/app/rest/changes?locator=build:(status:FAILED,project:ProjectName,lookupLimit:1)
这应该返回与上次失败的构建相关的更改,我尚未测试,因为我不使用 TeamCity。
另请参阅以下内容 StackOverflow question为了获得特定版本的更改。
关于api - TeamCity REST API : Who broke the build?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22326364/