Repository navigation
Expand file tree
/
Copy pathDirectory.Build.props
More file actions
79 lines (70 loc) · 4.1 KB
/
Copy pathDirectory.Build.props
File metadata and controls
79 lines (70 loc) · 4.1 KB
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
<Project>
<!-- Encina Version -->
<PropertyGroup>
<VersionPrefix>0.14.0</VersionPrefix>
<VersionSuffix>dev</VersionSuffix>
</PropertyGroup>
<!-- Package Metadata -->
<PropertyGroup Condition="'$(MSBuildProjectExtension)' == '.csproj'">
<Authors>David Lozano Rivada</Authors>
<RepositoryUrl>https://github.com/dlrivada/Encina</RepositoryUrl>
<RepositoryType>git</RepositoryType>
</PropertyGroup>
<PropertyGroup Condition="'$(MSBuildProjectExtension)' == '.csproj'">
<TargetFramework Condition="'$(TargetFramework)' == ''">net10.0</TargetFramework>
<Nullable Condition="'$(Nullable)' == ''">enable</Nullable>
<ImplicitUsings Condition="'$(ImplicitUsings)' == ''">enable</ImplicitUsings>
<LangVersion Condition="'$(LangVersion)' == ''">14.0</LangVersion>
<EnableNETAnalyzers Condition="'$(EnableNETAnalyzers)' == ''">true</EnableNETAnalyzers>
<AnalysisMode Condition="'$(AnalysisMode)' == ''">Recommended</AnalysisMode>
<AnalysisLevel Condition="'$(AnalysisLevel)' == ''">latest</AnalysisLevel>
<EnforceCodeStyleInBuild Condition="'$(EnforceCodeStyleInBuild)' == ''">true</EnforceCodeStyleInBuild>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<WarningsAsErrors>$(WarningsAsErrors);CS*;IL*;NU*;IDE*;SYSLIB*</WarningsAsErrors>
</PropertyGroup>
<!-- Static Code Analyzers (all projects) -->
<ItemGroup Condition="'$(MSBuildProjectExtension)' == '.csproj'">
<PackageReference Include="Meziantou.Analyzer">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="SonarAnalyzer.CSharp">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Roslynator.Analyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
<PropertyGroup>
<_ProjectDirectoryNormalized>$([System.String]::Copy('$(MSBuildProjectDirectory)').Replace('\','/').ToLowerInvariant())</_ProjectDirectoryNormalized>
</PropertyGroup>
<PropertyGroup Condition="$([System.String]::Copy('$(_ProjectDirectoryNormalized)').Contains('/tests/'))">
<IsPackable Condition="'$(IsPackable)' == ''">false</IsPackable>
</PropertyGroup>
<!--
Every project under src/ ships as a NuGet package (SPEC-000 REQ-001: one authoritative list of
what ships; the path rule derives that list from src/ instead of repeating it in each csproj).
An exception is a single <IsPackable>false</IsPackable> in its csproj, recorded by the package
manifest of #1362. Projects under tools/ are not covered; they set IsPackable themselves.
-->
<PropertyGroup Condition="$([System.String]::Copy('$(_ProjectDirectoryNormalized)').Contains('/src/'))">
<IsPackable Condition="'$(IsPackable)' == ''">true</IsPackable>
</PropertyGroup>
<!-- xunit.analyzers (test projects only) -->
<ItemGroup Condition="$([System.String]::Copy('$(_ProjectDirectoryNormalized)').Contains('/tests/'))">
<PackageReference Include="xunit.analyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
<!-- Explicitly mark src projects as MAIN for SonarCloud coverage analysis -->
<PropertyGroup Condition="$([System.String]::Copy('$(_ProjectDirectoryNormalized)').Contains('/src/'))">
<SonarQubeTestProject>false</SonarQubeTestProject>
</PropertyGroup>
<!-- Explicitly mark tests/benchmarks/load projects as TEST for SonarCloud -->
<PropertyGroup Condition="$([System.String]::Copy('$(_ProjectDirectoryNormalized)').Contains('/tests/')) Or $([System.String]::Copy('$(_ProjectDirectoryNormalized)').Contains('/benchmarks/')) Or $([System.String]::Copy('$(_ProjectDirectoryNormalized)').Contains('/load/'))">
<SonarQubeTestProject>true</SonarQubeTestProject>
</PropertyGroup>
</Project>