Skip to content

Commit b42ebf1

Browse files
committed
Fix incrementalism of Blazor solution
1 parent 1434e23 commit b42ebf1

File tree

3 files changed

+29
-20
lines changed

3 files changed

+29
-20
lines changed

Diff for: src/Components/Blazor/Build/src/ReferenceFromSource.props

+6-7
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,11 @@
4646
<SkipGetTargetFrameworkProperties>true</SkipGetTargetFrameworkProperties>
4747
<UndefineProperties>TargetFramework</UndefineProperties>
4848
</ProjectReference>
49+
<ProjectReference Include="$(MSBuildThisFileDirectory)..\..\DevServer\src\Microsoft.AspNetCore.Blazor.DevServer.csproj">
50+
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
51+
<!-- Optimization. Do not require framework compatibility between these projects. -->
52+
<SkipGetTargetFrameworkProperties>true</SkipGetTargetFrameworkProperties>
53+
<UndefineProperties>TargetFramework</UndefineProperties>
54+
</ProjectReference>
4955
</ItemGroup>
50-
51-
<PropertyGroup>
52-
<!-- When referencing from source, we need to disable VS's fast up-to-date check,
53-
because otherwise changing the underlying Blazor library code isn't enough
54-
to make it rebuild the affected library apps. -->
55-
<DisableFastUpToDateCheck>true</DisableFastUpToDateCheck>
56-
</PropertyGroup>
5756
</Project>

Diff for: src/Components/Blazor/Templates/src/Microsoft.AspNetCore.Blazor.Templates.csproj

+20-12
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
<Project>
2-
<Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk" />
1+
<Project Sdk="Microsoft.NET.Sdk">
32
<PropertyGroup>
43
<TargetFramework>netstandard2.0</TargetFramework>
54
<NuspecFile>Microsoft.AspNetCore.Blazor.Templates.nuspec</NuspecFile>
@@ -16,18 +15,31 @@
1615
<IsProjectReferenceProvider>false</IsProjectReferenceProvider>
1716
</PropertyGroup>
1817

19-
<Target Name="TransformTemplateConfigs" BeforeTargets="CoreBuild" DependsOnTargets="SetTemplateJsonSymbolReplacements">
20-
<!--
21-
For each template, copy its '.template.config.src' directory to '.template.config',
22-
removing any earlier output at that location
23-
-->
18+
<ItemGroup>
19+
<UpToDateCheckInput Include="content\**\.template.config.src\**\*.*" />
20+
</ItemGroup>
21+
22+
<Target Name="PrepareFileLists" AfterTargets="PrepareForBuild">
2423
<ItemGroup>
2524
<_TemplateConfigMainFile Include="content\**\.template.config.src\template.json" />
26-
<_TemplateConfigDir Include="@(_TemplateConfigMainFile-&gt;'$([System.IO.Path]::GetDirectoryName('%(_TemplateConfigMainFile.FullPath)'))')" />
25+
<_TemplateConfigDir Include="@(_TemplateConfigMainFile->'$([System.IO.Path]::GetDirectoryName('%(_TemplateConfigMainFile.FullPath)'))')" />
2726
<_TemplateConfigFileToCopy Include="%(_TemplateConfigDir.Identity)\**\*.*">
2827
<DestDir>$([System.IO.Path]::GetDirectoryName('%(_TemplateConfigDir.Identity)'))\.template.config\</DestDir>
2928
</_TemplateConfigFileToCopy>
3029
</ItemGroup>
30+
</Target>
31+
32+
<Target
33+
Name="TransformTemplateConfigs"
34+
BeforeTargets="CoreBuild"
35+
DependsOnTargets="SetTemplateJsonSymbolReplacements"
36+
Inputs="@(_TemplateConfigFileToCopy)"
37+
Outputs="@(_TemplateConfigFileToCopy->'%(DestDir)%(FileName)%(Extension)')">
38+
39+
<!--
40+
For each template, copy its '.template.config.src' directory to '.template.config',
41+
removing any earlier output at that location
42+
-->
3143
<RemoveDir Directories="%(_TemplateConfigFileToCopy.DestDir)" />
3244
<Copy SourceFiles="%(_TemplateConfigFileToCopy.Identity)" DestinationFolder="%(_TemplateConfigFileToCopy.DestDir)" />
3345

@@ -49,8 +61,4 @@
4961
<Output TaskParameter="OutputPath" ItemName="Content" />
5062
</GenerateFileFromTemplate>
5163
</Target>
52-
<Import Project="Sdk.targets" Sdk="Microsoft.NET.Sdk" />
53-
<!-- Override SDK targets. This project does not produce a .dll. -->
54-
<Target Name="CoreCompile" />
55-
<Target Name="GetTargetPath" />
5664
</Project>

Diff for: src/Servers/IIS/IIS/src/Microsoft.AspNetCore.Server.IIS.csproj

+3-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
<PackageTags>aspnetcore;iis</PackageTags>
1111
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
1212
<NativeAssetsTargetFramework>netcoreapp3.0</NativeAssetsTargetFramework>
13-
<DisableFastUpToDateCheck>True</DisableFastUpToDateCheck>
1413
</PropertyGroup>
1514

1615
<ItemGroup>
@@ -44,6 +43,9 @@
4443
</ItemGroup>
4544

4645
<Import Project="..\..\build\assets.props" />
46+
<ItemGroup>
47+
<UpToDateCheckInput Include="@(InProcessComponents)" />
48+
</ItemGroup>
4749

4850
<Target Name="AddPackNativeComponents" BeforeTargets="_GetPackageFiles" Condition="$(PackNativeAssets) == 'true'">
4951
<ItemGroup>

0 commit comments

Comments
 (0)