Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

TeamCity's AssemblyInfo patcher's number format

I once had TeamCity + WiX + MSBuild Community Tasks working. Now that I've upgraded to WiX 3.5, I can't remember how I had configured it. :) As I was poking through TeamCity, I came across the "AssemblyInfo Patcher". I thought, "Great! This will make my life much easier!". I used %build.vcs.number.1% for the format and built my installer.

While the patcher did pull in the vcs number, it used it for the major number in the version. So instead of 1.0.0.xxxx, it made the version xxxx.0.0.0.

I looked through JetBrain's documentation site and came up with nothing related to changing this to a more appropriate setting. I also looked for regex support, but didn't find anything.

Can anyone suggest a good solution, or should I just go back to trying to configure my original set of tools?

like image 214
Dave Avatar asked Jul 26 '11 14:07

Dave


2 Answers

The assembly info patcher only patches the complete version string at once. But the system variable build.number can be generated from the "general" page of the build configuration, like this: General settings

When you specify %build.number% as your AssemblyInfo version, it will pick up the combined number from your General settings page.Assermbly info patcher

like image 135
Per-Frode Pedersen Avatar answered Oct 20 '22 15:10

Per-Frode Pedersen


Try including the full intended version number as part of your format:

1.0.0.%build.vcs.number.1%
like image 35
Bilal Avatar answered Oct 20 '22 16:10

Bilal