Does TeamCity have a system / environment variable for the current build configuration identifier?

In TeamCity, if you know the build configuration identifier, you can create URLs like this:

http://example.org/guestAuth/repository/download/bt222/.lastSuccessful/exampleBuild.zip

But look, what is "bt222"? This is the assembly configuration identifier; it is generated by TC when configuring assembly and static. Atlassian docs seem to say that the way to determine this is to look at your URL on the screen.

The thing is, I need to get it programmatically, in an msbuild script, so that the same build script can serve multiple build configurations. TC otherwise there are so many nice convenient variables that I just hope I missed it somehow ...

+5
source share
3 answers

Do this as a parameter for your build script and set it in the build configuration settings from the outside.

The build script should not depend on the build server, it should also work locally.

+3
source

Configuration ID is available as %system.teamcity.buildType.id%.

Tested to work in Teamcity 7.1.5

+7
source

, , , ? ? .

0

All Articles