Fixups
This commit is contained in:
parent
b289633533
commit
f3a1fb6ad3
|
|
@ -109,7 +109,7 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.Compon
|
|||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.Components.WebAssembly.Server.Tests", "WebAssembly\Server\test\Microsoft.AspNetCore.Components.WebAssembly.Server.Tests.csproj", "{72D3D00C-5281-455F-9E19-646EE766009A}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.Components.WebAssembly.HttpHandler", "WebAssembly\WebAssemblyHttpHandler\src\Microsoft.AspNetCore.Comopnents.WebAssembly.HttpHandler.csproj", "{52744BCB-1046-48C0-93A4-19A311A907B2}"
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.Components.WebAssembly.HttpHandler", "WebAssembly\WebAssemblyHttpHandler\src\Microsoft.AspNetCore.Components.WebAssembly.HttpHandler.csproj", "{52744BCB-1046-48C0-93A4-19A311A907B2}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
|
|
|
|||
|
|
@ -15,31 +15,26 @@
|
|||
Condition="'$(BlazorPrunePublishOutput)' != 'false'">
|
||||
|
||||
<ItemGroup>
|
||||
<!-- Delete stray DLLs from the application. -->
|
||||
<!-- Delete stray contents from the root of the the app. -->
|
||||
<ResolvedFileToPublish
|
||||
Remove="%(ResolvedFileToPublish.Identity)"
|
||||
Condition="$([System.String]::Copy('%(ResolvedFileToPublish.RelativePath)').EndsWith('dll'))"/>
|
||||
<!--Remove stray debugging files.-->
|
||||
<ResolvedFileToPublish
|
||||
Remove="%(ResolvedFileToPublish.Identity)"
|
||||
Condition="$([System.String]::Copy('%(ResolvedFileToPublish.RelativePath)').EndsWith('pdb'))"/>
|
||||
<!--Remove excluded static assets.-->
|
||||
<ResolvedFileToPublish
|
||||
Remove="%(ResolvedFileToPublish.Identity)"
|
||||
Condition="$([System.String]::Copy('%(ResolvedFileToPublish.RelativePath)').Replace('\','/').StartsWith('Excluded-Static-Web-Assets/'))"/>
|
||||
Condition="'%(ResolvedFileToPublish.RelativePath)' != 'web.config' AND !$([System.String]::Copy('%(ResolvedFileToPublish.RelativePath)').Replace('\','/').StartsWith('wwwroot/'))"/>
|
||||
</ItemGroup>
|
||||
</Target>
|
||||
|
||||
<!--After moving the resolved files to the publish directory, we can determine
|
||||
whether or not to copy the standalone config if the user has not provided
|
||||
their own.-->
|
||||
<Target
|
||||
Name="_BlazorCopyStandaloneWebConfig"
|
||||
AfterTargets="CopyFilesToPublishDirectory"
|
||||
Condition="!Exists('$(PublishDir)web.config')">
|
||||
<WriteLinesToFile
|
||||
File="$(PublishDir)web.config"
|
||||
Lines="$([System.IO.File]::ReadAllText('$(MSBuildThisFileDirectory)Standalone.Web.config'))" />
|
||||
AfterTargets="_BlazorCleanupPublishOutput;ComputeResolvedFilesToPublishList"
|
||||
Condition="'@(ResolvedFileToPublish->AnyHaveMetadataValue('RelativePath', 'web.config'))' != 'true'">
|
||||
|
||||
<ItemGroup>
|
||||
<ResolvedFileToPublish Include="$(MSBuildThisFileDirectory)Standalone.Web.config">
|
||||
<ExcludeFromSingleFile>true</ExcludeFromSingleFile>
|
||||
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
|
||||
<RelativePath>web.config</RelativePath>
|
||||
</ResolvedFileToPublish>
|
||||
</ItemGroup>
|
||||
|
||||
</Target>
|
||||
|
||||
</Project>
|
||||
</Project>
|
||||
|
|
@ -117,8 +117,6 @@ namespace Microsoft.AspNetCore.Components.WebAssembly.Build
|
|||
|
||||
var publishDirectory = project.PublishOutputDirectory;
|
||||
|
||||
var blazorPublishDirectory = Path.Combine(publishDirectory, "wwwroot");
|
||||
|
||||
// Verify web.config
|
||||
Assert.FileExists(result, publishDirectory, "web.config");
|
||||
Assert.FileContains(result, Path.Combine(publishDirectory, "web.config"), webConfigContents);
|
||||
|
|
@ -421,7 +419,6 @@ namespace Microsoft.AspNetCore.Components.WebAssembly.Build
|
|||
File.WriteAllText(path, content);
|
||||
}
|
||||
|
||||
|
||||
private static void VerifyBootManifestHashes(MSBuildResult result, string blazorPublishDirectory)
|
||||
{
|
||||
var bootManifestResolvedPath = Assert.FileExists(result, blazorPublishDirectory, "_framework", "blazor.boot.json");
|
||||
|
|
|
|||
Loading…
Reference in New Issue