Include .Views.dll from single file in .NET Core 3.1 apps (#27897)

For 5.0, we made a change to exclude .Views.dll from the single file bundle as a reaction
to changes in bundling. However the SDK change also applied to .NET 3.1 apps. This change
limits the exclusion to 5.0 and newer apps.

Fixes https://github.com/dotnet/aspnetcore/issues/27831
This commit is contained in:
Pranav K 2020-11-19 11:41:00 -08:00 committed by GitHub
parent de177e3a80
commit f1ed2df88f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -724,12 +724,13 @@ Copyright (c) .NET Foundation. All rights reserved.
<AllPublishItemsFullPathWithTargetPath Include="@(RazorIntermediateAssembly->'%(FullPath)')">
<TargetPath>%(Filename)%(Extension)</TargetPath>
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
<ExcludeFromSingleFile>true</ExcludeFromSingleFile>
<!-- .Views.dll and .Views.pdb were part of the single file bundle in 3.1 apps. Lets keep this unchanged. -->
<ExcludeFromSingleFile Condition="'$(_TargetingNET50OrLater)' == 'true'">true</ExcludeFromSingleFile>
</AllPublishItemsFullPathWithTargetPath>
<AllPublishItemsFullPathWithTargetPath Include="@(_RazorDebugSymbolsIntermediatePath->'%(FullPath)')">
<TargetPath>%(Filename)%(Extension)</TargetPath>
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
<ExcludeFromSingleFile>true</ExcludeFromSingleFile>
<ExcludeFromSingleFile Condition="'$(_TargetingNET50OrLater)' == 'true'">true</ExcludeFromSingleFile>
</AllPublishItemsFullPathWithTargetPath>
</ItemGroup>