Logo Questions Linux Laravel Mysql Ubuntu Git Menu

Different TeamCity build counter per git branch

We use gitflow and TeamCity to develop many of our products. We also need to support multiple releases at the same time and work on the next release.

We use support branches for previous releases and develop and master as our current and future releases which is pretty standard I think.

Is there an easy way to have a build counter set up in TeamCity for each branch without needing to check this into the repo or having different configs for each release?

For instance I want my version on one support branch I want 1.0.1.(count of builds for version 1), on develop/master I want 2.0.0.(count of builds for version 2).

I know I can check the version in at the end of the build but was hoping there was a nicer way, we don't check anything in at the moment.

like image 749
user3236325 Avatar asked Nov 09 '22 21:11


1 Answers

No, not that I'm aware of. Currently (in TC 9.0), each branch uses the same build config. The only way I know to do what you're asking is to create a template (so all build steps would use the same template to avoid duplication) then create multiple build configs, each linked to a particular branch of the VCS.

like image 190
Japster24 Avatar answered Nov 15 '22 04:11