Skip to content

Commit 8fe597a

Browse files
author
Izzy Lancaster
committed
Configure Directory.Build.props
1 parent fd5e644 commit 8fe597a

File tree

2 files changed

+22
-8
lines changed

2 files changed

+22
-8
lines changed

Directory.Build.props

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,27 @@
11
<Project>
2-
<!-- See https://aka.ms/dotnet/msbuild/customize for more details on customizing your build -->
3-
<PropertyGroup>
2+
<PropertyGroup Label="Versions">
3+
<!-- Custom msbuild properties used in the project -->
4+
<RepositoryTargetFrameworkVersion>net8.0</RepositoryTargetFrameworkVersion>
5+
</PropertyGroup>
6+
7+
<!-- Settings for all projects. Can be overridden in the .csproj file. -->
8+
<PropertyGroup Label="Global Settings">
9+
<TargetFramework>$(RepositoryTargetFrameworkVersion)</TargetFramework>
10+
<RollForward>LatestMinor</RollForward>
411

12+
<!-- Implicitly adds some using directives for System.* namespaces. -->
13+
<ImplicitUsings>enable</ImplicitUsings>
14+
<!-- Enable null-checking for everything. -->
15+
<Nullable>enable</Nullable>
516

17+
<!-- Turn on code analysis.-->
18+
<AnalysisMode>Recommended</AnalysisMode>
19+
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild>
20+
<EnableNETAnalyzers>true</EnableNETAnalyzers>
21+
22+
</PropertyGroup>
23+
24+
<PropertyGroup Condition="'$(GITHUB_ACTIONS)' == 'true'">
25+
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
626
</PropertyGroup>
727
</Project>
Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,3 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

3-
<PropertyGroup>
4-
<TargetFramework>net9.0</TargetFramework>
5-
<ImplicitUsings>enable</ImplicitUsings>
6-
<Nullable>enable</Nullable>
7-
</PropertyGroup>
8-
93
</Project>

0 commit comments

Comments
 (0)