stack72 / TeamCitySharp

No Longer Maintained - please use https://github.com/mavezeau/TeamCitySharp
Other
200 stars 165 forks source link

Does the API collect builds from all branches? #106

Open AMoghrabi opened 8 years ago

AMoghrabi commented 8 years ago

This is primarily a question for https://github.com/mavezeau/TeamCitySharp as this project seems to be dead.

Is it possible to collect all builds for all branches, not just the default branch?

Thanks.

borismod commented 8 years ago

That's nice to see, that there is an active fork of TeamCitySharp. Regarding your question, you may see the implementation of GetBuilds method in FluentTc, which allows retrieving with all branches and/or specific branch:

Here is an example:

            IList<IBuild> builds =
                new RemoteTc().Connect(_ => _.ToHost("teamcity.codebetter.com").AsGuest())
                    .GetBuilds(b => 
                        b.BuildConfiguration(c => 
                            c.Id("FluentTc_FluentTcDevelop"))
                                .Branch(r => r.Branched()));