Browse Source
Set the ConfigureAwait weaver default with a shared MSBuild property
pull/26078/head
maliming
4 days ago
No known key found for this signature in database
GPG Key ID: A646B9CB645ECEA4
2 changed files with
34 additions and
0 deletions
-
configureawait.props
-
templates/module/aspnet-core/common.props
|
|
|
@ -6,4 +6,22 @@ |
|
|
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> |
|
|
|
</PackageReference> |
|
|
|
</ItemGroup> |
|
|
|
|
|
|
|
<!-- The xsd only feeds editor completion and Fody rewrites it on every run. --> |
|
|
|
<PropertyGroup> |
|
|
|
<FodyGenerateXsd>false</FodyGenerateXsd> |
|
|
|
</PropertyGroup> |
|
|
|
|
|
|
|
<!-- Component assemblies keep their own FodyWeavers.xml: their lifecycle methods must |
|
|
|
resume on the renderer's synchronization context. Unconditional because a solution |
|
|
|
build compiles cross-solution project references with the default configuration. --> |
|
|
|
<PropertyGroup Condition="$(MSBuildProjectName.EndsWith('.Bundling')) |
|
|
|
Or (!$(MSBuildProjectName.Contains('Blazor')) |
|
|
|
And !$(MSBuildProjectName.Contains('AspNetCore.Components')))"> |
|
|
|
<WeaverConfiguration Condition="'$(WeaverConfiguration)' == ''"> |
|
|
|
<Weavers> |
|
|
|
<ConfigureAwait ContinueOnCapturedContext="false" /> |
|
|
|
</Weavers> |
|
|
|
</WeaverConfiguration> |
|
|
|
</PropertyGroup> |
|
|
|
</Project> |
|
|
|
|
|
|
|
@ -14,7 +14,23 @@ |
|
|
|
</PackageReference> |
|
|
|
</ItemGroup> |
|
|
|
|
|
|
|
<!-- The xsd only feeds editor completion and Fody rewrites it on every run. --> |
|
|
|
<PropertyGroup> |
|
|
|
<FodyGenerateXsd>false</FodyGenerateXsd> |
|
|
|
</PropertyGroup> |
|
|
|
|
|
|
|
<!-- Component assemblies keep their own FodyWeavers.xml: their lifecycle methods must |
|
|
|
resume on the renderer's synchronization context. Unconditional because a solution |
|
|
|
build compiles cross-solution project references with the default configuration. --> |
|
|
|
<PropertyGroup Condition="$(MSBuildProjectName.EndsWith('.Bundling')) |
|
|
|
Or (!$(MSBuildProjectName.Contains('Blazor')) |
|
|
|
And !$(MSBuildProjectName.Contains('AspNetCore.Components')))"> |
|
|
|
<WeaverConfiguration Condition="'$(WeaverConfiguration)' == ''"> |
|
|
|
<Weavers> |
|
|
|
<ConfigureAwait ContinueOnCapturedContext="false" /> |
|
|
|
</Weavers> |
|
|
|
</WeaverConfiguration> |
|
|
|
</PropertyGroup> |
|
|
|
<Target Name="NoWarnOnRazorViewImportedTypeConflicts" BeforeTargets="RazorCoreCompile"> |
|
|
|
<PropertyGroup> |
|
|
|
<NoWarn>$(NoWarn);0436</NoWarn> |
|
|
|
|