Split out from #103 (item 3).
Summary
In Release the SDK sets MvcBuildViews=true and runs the AspNetCompiler task in the MvcBuildViews target. That task ships only with the full .NET Framework MSBuild, so under dotnet (Core MSBuild) the build fails with:
error MSB4803: The task "AspNetCompiler" is not supported on the .NET Core version of MSBuild.
Proposed change
Under Core MSBuild, replace the cryptic MSB4803 with a clear, actionable message (e.g. SYSWEB002) that explains AspNetCompiler is unavailable on the .NET Core MSBuild used by dotnet, and that the step can be skipped intentionally by setting:
<!-- e.g. in Directory.Build.props -->
<MvcBuildViews Condition="'$(MSBuildRuntimeType)' == 'Core'">false</MvcBuildViews>
Skipping stays opt-in (the user's explicit choice); precompiling views with the full Visual Studio MSBuild is unchanged.
(Open to either: a hard error with the guidance above, or a non-fatal message + skip behind an opt-in property — whichever you prefer.)
Split out from #103 (item 3).
Summary
In
Releasethe SDK setsMvcBuildViews=trueand runs theAspNetCompilertask in theMvcBuildViewstarget. That task ships only with the full .NET Framework MSBuild, so underdotnet(Core MSBuild) the build fails with:Proposed change
Under Core MSBuild, replace the cryptic
MSB4803with a clear, actionable message (e.g.SYSWEB002) that explainsAspNetCompileris unavailable on the .NET Core MSBuild used bydotnet, and that the step can be skipped intentionally by setting:Skipping stays opt-in (the user's explicit choice); precompiling views with the full Visual Studio MSBuild is unchanged.
(Open to either: a hard error with the guidance above, or a non-fatal message + skip behind an opt-in property — whichever you prefer.)