Skip to content

Instantly share code, notes, and snippets.

@jonpryor
Created September 9, 2021 15:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jonpryor/2f0bb771d99d68a989904c093a144871 to your computer and use it in GitHub Desktop.
Save jonpryor/2f0bb771d99d68a989904c093a144871 to your computer and use it in GitHub Desktop.
% dotnet build /nologo /v:m x.targets /t:Foo
IsNet6IosCompatibleWithNet6=
Build succeeded.
0 Warning(s)
0 Error(s)
Time Elapsed 00:00:00.09
% msbuild /v:m /nologo x.targets /t:Foo
IsNet6IosCompatibleWithNet6=
<Project>
<PropertyGroup>
<IsNet6IosCompatibleWithNet6 Condition="$([MSBuild]::IsTargetFrameworkCompatible('net6.0', 'net6.0-ios'))">Yes</IsNet6IosCompatibleWithNet6>
</PropertyGroup>
<Target Name="Foo">
<Message Text="IsNet6IosCompatibleWithNet6=$(IsNet6IosCompatibleWithNet6)" />
</Target>
</Project>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment