Reputation: 764
Is there a way to retrieve comment message of teamcity build during its run.
From the wiki from Teamcity noticed there are ways to reach & retrieve server build / agent build properties : http://confluence.jetbrains.com/display/TCD7/Predefined+Build+Parameters
I would like to know, if there exists a solution to retrieve comment message string from the build. If few are present under pending changes, then it has to retrieve it with some line separator.
With system properties, if we define/add new property in the build in what format it gets retrieved when we somehow parse : teamcity.build.properties.file
Thanks,
Upvotes: 3
Views: 819
Reputation: 3099
In order to retrieve comments of a build you can use TeamCity REST API:
If you need it from C# project, you may consider using FluentTc library:
IBuild build = new RemoteTc()
.Connect(_ => _.ToHost("teamcity.codebetter.com").AsGuest())
.GetLastBuild(
having => having.Id(216886),
with => with.IncludeChanges(and => and.IncludeComment()));
Upvotes: 0