-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDirectory.Build.props
37 lines (32 loc) · 1.64 KB
/
Directory.Build.props
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<Project>
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<GenerateDocumentationFile>True</GenerateDocumentationFile>
<!-- Define a custom property. Set to true to use the NuGet package -->
<UseNuGetForYAFLHttp Condition="'$(Configuration)' == 'Release'">true</UseNuGetForYAFLHttp>
<UseNuGetForYAFLHttp Condition="'$(UseNuGetForYAFLHttp)' == ''">false</UseNuGetForYAFLHttp>
<!-- Configure code analysis. -->
<AnalysisLevel>latest</AnalysisLevel>
<AnalysisMode>All</AnalysisMode>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<CodeAnalysisTreatWarningsAsErrors>false</CodeAnalysisTreatWarningsAsErrors>
<EnforceCodeStyleInBuild>false</EnforceCodeStyleInBuild>
</PropertyGroup>
<ItemGroup Condition="'$(MSBuildProjectExtension)' != '.dcproj'">
<PackageReference Include="SonarAnalyzer.CSharp">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
<ItemGroup Condition="'$(UseNuGetForYAFLHttp)' == 'true'">
<!-- Use the YAFLHttp NuGet package in Release mode -->
<PackageReference Include="YAFLHttp" Condition="'$(MSBuildProjectName)' != 'FluentHttpClient'" />
</ItemGroup>
<ItemGroup Condition="'$(UseNuGetForYAFLHttp)' == 'false'">
<!-- Use the local project reference in Debug mode -->
<ProjectReference Include="..\FluentHttpClient\FluentHttpClient.csproj"
Condition="'$(MSBuildProjectName)' != 'FluentHttpClient'" />
</ItemGroup>
</Project>