views:

565

answers:

1

Is there any way to get TeamCity's build numbering to match the publish version (ApplicationRevision) number generated by MSBuild's publish task?

+4  A: 

You can control the build number in TeamCity via a specially formatted message in the build log. This can be output at any stage (e.g. during publish) and will cause the initially assigned build number to change. See here for more info.

For example, our msbuild has this to output the version as the build number:

<Message Text="##teamcity[buildNumber '$(FullVersion)']"/>
mancaus
Excellent, didn't know that one.
Todd