Make it possible to append a build number when using OctoPack
Octopack can parse AssemblyVesion attributes to extract version information, which is great. This enabled me to control the version of the generated NuGetPackage at the time when I check in my project. I like that. My build server generates new packages for every commit to out repository (even though the version might now have changed). Therefore I would like to be able to append the build number to the package Id. This could be done using an OctoPack parameter "OctoPackBuildNumber"
Example: AssemblyInfo.cs: [assembly: AssemblyVersion("188.8.131.52")]
then the buildserver passes in: /OctoPackBuildNumber -build%build.number%
Jason Burch commented
What about using this option during your build /p:OctoPackPackageVersion=1.1.%BUILD_NUMBER%
The Build_Number is a parameter you would pass in.
For example I use Jenkins and in my MSBUILD parameters I pass in the BUILD_NUMBER environment variable.
Emil Goude commented
I know this can be accomplished using custom NuSpec-file, or custom msbuild-scripts but then I would lose the built in ability of OctoPack to extract the version number from assemblyinfo, which is very convenient.