When you are not using .Net Core you could define your Assembly version in AssemblyInfo.cs
like so [assembly: AssemblyVersion("2.1.3.*")]
. Note in particular the *
which means the default build number
In .Net core as far as I can tell the build number is set in the *.csproj
file. However, it appears to not like using an *
in version. It complains that version number is invalid.
<PropertyGroup>
<AssemblyVersion>2.1.3.*</AssemblyVersion>
</PropertyGroup>
I have raised an issue on the dotnet/cli project, but to no avail.
So my question is 'How to set default build number in .Net Core'?