Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
ParseAssemblyInfo does not support .NET Core generated assembly info #2473
What You Are Seeing?
When parsing an AssemblyInfo file generated by the .NET Core SDK on build no information is returned. e.g. AssemblyInformationalVersion returns the default value of 1.0.0 rather than my specified version.
What is Expected?
The correct information is returned.
What version of Cake are you using?
Are you running on a 32 or 64 bit system?
What environment are you running on? Windows? Linux? Mac?
Are you running on a CI Server? If so, which one?
How Did You Get This To Happen? (Steps to Reproduce)
Parse the generated AssemblyInfo file using
The reason this is not working is that the generated AssemblyInfo in .NET Core projects uses the full attribute type name rather than the typically shortened type name. Cake uses the shorter name as seen here whereas .NET core Projects will have
An alternative regex that would work for all cases would be this: https://regex101.com/r/Teupyl/1 and modified to allow for the string format substitution:
@Joev- actually, I might have misread your issue....
I thought you were referring to the new csproj format, not an AssemblyInfo file. I am not sure if there is a new parser for that in Incubator or not. If not, come back here and we can investigate.
Sorry to mess you around!