How can I access to commits list in BuildServiceAdapter

I'm creating custom plugin for Teamcity. And I need to get list of commits from last succsefull build. How can I get it?
You documentation is very poor.

0
4 comments
Official comment

Hi,

There's no update, we still not planning to add such functionality to agent side.

You may try to use REST API to fetch information from server during a build.

 

Regards,

Vladislav.

Hi Alexey,

There no such information available on agent side of TeamCity.
Agent have access only to files(changes) in currently running build. From BuildServerAdapter you could use `getBuild().getVcsChanges()` call chain to get chagnes in this build.

On server side you could use Build#getChanges method.

Why do you need changes since last succesfull build on agent side? Maybe there's another way to achive your goal?

Regards,
Vladislav

0
Avatar
Permanently deleted user

Hello (: Is there any update about this topic? Are agents still not able to access build changes?

Or maybe there is more convenient way to do this?

I just want to get list of commits that differ with previous build, because I want to parse comments from them to add as release notes. Is there any way to achieve that?

Or maybe I can access pending changes list?

 

Thank you in advance!

0
Avatar
Permanently deleted user

Thank you for comment. Yeah, I already started looking into REST API, and found some ways to get what I want. But I still have not found info about getting pending changes from API - could you, please, guide me?

0

Please sign in to leave a comment.