cake-contrib / Cake.Incubator

This project contains various experimental but useful extension methods and aliases for Cake
http://cakebuild.net/api/Cake.Incubator/
Other
19 stars 23 forks source link

dotnet 5 not recognized as netcore #116

Closed mryanmurphy closed 3 years ago

mryanmurphy commented 3 years ago

net5.0 should be parsed as a netcore target framework instead of a netframework target framework.

In all of the codepaths that include a conditional on IsNetCore, the wrong branch is taken for net5.0 trying to treat it as net framework csproj file.

https://github.com/cake-contrib/Cake.Incubator/blob/ccccbc0ae68a3a8156769286eee1daab9a7989da/src/Cake.Incubator/Project/ProjectParserExtensions.cs#L34-L36

nils-a commented 3 years ago

One point here is that net5.0 is not matched as IsNetCore, the other that there is no IsNet (or IsNet5Plus or something like that) is missing entirely.

Additionally, looking at the RegEx, the TFMs for "Windows Store" (netcore, netcore45, netcore451) would be wrongly recognized as IsNetCore

(And, on a sidenote, the RegEx seem to awfully complex for the task required...)

cake-contrib-bot commented 2 years ago

:tada: This issue has been resolved in version 7.0.0 :tada:

The release is available on:

Your GitReleaseManager bot :package::rocket: