From 87704ce036fb23a4174b8290f249706aa35ab255 Mon Sep 17 00:00:00 2001 From: Matt Thalman Date: Wed, 19 Apr 2023 18:28:28 -0500 Subject: [PATCH] Use net8.0 TFM when building with source-build (#2150) * Use net8.0 TFM when building with source-build * Revert changes to sample projects --- Directory.Build.props | 6 +++--- .../System.CommandLine.ApiCompatibility.Tests.csproj | 2 +- .../System.CommandLine.Benchmarks.csproj | 2 +- .../System.CommandLine.DragonFruit.Tests.csproj | 2 +- .../System.CommandLine.Generator.Tests.csproj | 2 +- .../System.CommandLine.Hosting.Tests.csproj | 2 +- .../System.CommandLine.Hosting.csproj | 2 +- .../System.CommandLine.NamingConventionBinder.Tests.csproj | 2 +- .../System.CommandLine.NamingConventionBinder.csproj | 2 +- .../System.CommandLine.Rendering.Tests.csproj | 2 +- .../EndToEndTestApp/EndToEndTestApp.csproj | 2 +- .../dotnet-suggest.Tests.csproj | 2 +- src/System.CommandLine.Suggest/dotnet-suggest.csproj | 2 +- .../System.CommandLine.Tests.csproj | 2 +- .../TestApps/NativeAOT/NativeAOT.csproj | 4 ++-- .../TestApps/Trimming/Trimming.csproj | 4 ++-- src/System.CommandLine/System.CommandLine.csproj | 4 ++-- 17 files changed, 22 insertions(+), 22 deletions(-) diff --git a/Directory.Build.props b/Directory.Build.props index 4c1f04a2fb..0444426a70 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -11,11 +11,11 @@ 10.0 - - net7.0 + + $(NetCurrent) - + net7.0 diff --git a/src/System.CommandLine.ApiCompatibility.Tests/System.CommandLine.ApiCompatibility.Tests.csproj b/src/System.CommandLine.ApiCompatibility.Tests/System.CommandLine.ApiCompatibility.Tests.csproj index a793cc4d64..4cc48fde3d 100644 --- a/src/System.CommandLine.ApiCompatibility.Tests/System.CommandLine.ApiCompatibility.Tests.csproj +++ b/src/System.CommandLine.ApiCompatibility.Tests/System.CommandLine.ApiCompatibility.Tests.csproj @@ -1,7 +1,7 @@ - net7.0 + $(TargetFrameworkForNETSDK) false diff --git a/src/System.CommandLine.Benchmarks/System.CommandLine.Benchmarks.csproj b/src/System.CommandLine.Benchmarks/System.CommandLine.Benchmarks.csproj index 04e0d65832..efd712a4a9 100644 --- a/src/System.CommandLine.Benchmarks/System.CommandLine.Benchmarks.csproj +++ b/src/System.CommandLine.Benchmarks/System.CommandLine.Benchmarks.csproj @@ -9,7 +9,7 @@ false - net7.0 + $(TargetFrameworkForNETSDK) False diff --git a/src/System.CommandLine.DragonFruit.Tests/System.CommandLine.DragonFruit.Tests.csproj b/src/System.CommandLine.DragonFruit.Tests/System.CommandLine.DragonFruit.Tests.csproj index e69b4a2c4b..b5090c97c5 100644 --- a/src/System.CommandLine.DragonFruit.Tests/System.CommandLine.DragonFruit.Tests.csproj +++ b/src/System.CommandLine.DragonFruit.Tests/System.CommandLine.DragonFruit.Tests.csproj @@ -1,6 +1,6 @@  - net7.0 + $(TargetFrameworkForNETSDK) AutoGeneratedProgram true diff --git a/src/System.CommandLine.Generator.Tests/System.CommandLine.Generator.Tests.csproj b/src/System.CommandLine.Generator.Tests/System.CommandLine.Generator.Tests.csproj index 402ca8d79a..20f0f410d9 100644 --- a/src/System.CommandLine.Generator.Tests/System.CommandLine.Generator.Tests.csproj +++ b/src/System.CommandLine.Generator.Tests/System.CommandLine.Generator.Tests.csproj @@ -1,6 +1,6 @@  - net7.0 + $(TargetFrameworkForNETSDK) $(TargetFrameworks);net462 true true diff --git a/src/System.CommandLine.Hosting.Tests/System.CommandLine.Hosting.Tests.csproj b/src/System.CommandLine.Hosting.Tests/System.CommandLine.Hosting.Tests.csproj index 9e9e3c23f3..8e2cd6ea40 100644 --- a/src/System.CommandLine.Hosting.Tests/System.CommandLine.Hosting.Tests.csproj +++ b/src/System.CommandLine.Hosting.Tests/System.CommandLine.Hosting.Tests.csproj @@ -1,7 +1,7 @@  - net7.0 + $(TargetFrameworkForNETSDK) $(TargetFrameworks);net462 false diff --git a/src/System.CommandLine.Hosting/System.CommandLine.Hosting.csproj b/src/System.CommandLine.Hosting/System.CommandLine.Hosting.csproj index acab3a977e..f47d3ecf03 100644 --- a/src/System.CommandLine.Hosting/System.CommandLine.Hosting.csproj +++ b/src/System.CommandLine.Hosting/System.CommandLine.Hosting.csproj @@ -2,7 +2,7 @@ true - netstandard2.0;netstandard2.1;net7.0 + netstandard2.0;netstandard2.1;$(TargetFrameworkForNETSDK) This package provides support for using System.CommandLine with Microsoft.Extensions.Hosting. diff --git a/src/System.CommandLine.NamingConventionBinder.Tests/System.CommandLine.NamingConventionBinder.Tests.csproj b/src/System.CommandLine.NamingConventionBinder.Tests/System.CommandLine.NamingConventionBinder.Tests.csproj index 4df7ca92d9..bce50a8011 100644 --- a/src/System.CommandLine.NamingConventionBinder.Tests/System.CommandLine.NamingConventionBinder.Tests.csproj +++ b/src/System.CommandLine.NamingConventionBinder.Tests/System.CommandLine.NamingConventionBinder.Tests.csproj @@ -1,6 +1,6 @@  - net7.0 + $(TargetFrameworkForNETSDK) $(TargetFrameworks);net462 10 diff --git a/src/System.CommandLine.NamingConventionBinder/System.CommandLine.NamingConventionBinder.csproj b/src/System.CommandLine.NamingConventionBinder/System.CommandLine.NamingConventionBinder.csproj index cf80841f38..8d941fdabd 100644 --- a/src/System.CommandLine.NamingConventionBinder/System.CommandLine.NamingConventionBinder.csproj +++ b/src/System.CommandLine.NamingConventionBinder/System.CommandLine.NamingConventionBinder.csproj @@ -3,7 +3,7 @@ true System.CommandLine.NamingConventionBinder - net7.0;netstandard2.0 + $(TargetFrameworkForNETSDK);netstandard2.0 10 enable This package provides command handler support for System.CommandLine performs parameter and model binding by matching option and argument names to parameter and property names. diff --git a/src/System.CommandLine.Rendering.Tests/System.CommandLine.Rendering.Tests.csproj b/src/System.CommandLine.Rendering.Tests/System.CommandLine.Rendering.Tests.csproj index b07314646e..afd6dc6a46 100644 --- a/src/System.CommandLine.Rendering.Tests/System.CommandLine.Rendering.Tests.csproj +++ b/src/System.CommandLine.Rendering.Tests/System.CommandLine.Rendering.Tests.csproj @@ -1,7 +1,7 @@ - net7.0 + $(TargetFrameworkForNETSDK) false diff --git a/src/System.CommandLine.Suggest.Tests/EndToEndTestApp/EndToEndTestApp.csproj b/src/System.CommandLine.Suggest.Tests/EndToEndTestApp/EndToEndTestApp.csproj index 186b884e98..76add0d5a9 100644 --- a/src/System.CommandLine.Suggest.Tests/EndToEndTestApp/EndToEndTestApp.csproj +++ b/src/System.CommandLine.Suggest.Tests/EndToEndTestApp/EndToEndTestApp.csproj @@ -6,7 +6,7 @@ Exe - net7.0 + $(TargetFrameworkForNETSDK) diff --git a/src/System.CommandLine.Suggest.Tests/dotnet-suggest.Tests.csproj b/src/System.CommandLine.Suggest.Tests/dotnet-suggest.Tests.csproj index e22ead7273..f1711a10e1 100644 --- a/src/System.CommandLine.Suggest.Tests/dotnet-suggest.Tests.csproj +++ b/src/System.CommandLine.Suggest.Tests/dotnet-suggest.Tests.csproj @@ -1,7 +1,7 @@ - net7.0 + $(TargetFrameworkForNETSDK) diff --git a/src/System.CommandLine.Suggest/dotnet-suggest.csproj b/src/System.CommandLine.Suggest/dotnet-suggest.csproj index 8ce30080ed..ce4bda1d6b 100644 --- a/src/System.CommandLine.Suggest/dotnet-suggest.csproj +++ b/src/System.CommandLine.Suggest/dotnet-suggest.csproj @@ -1,7 +1,7 @@  Exe - net7.0 + $(TargetFrameworkForNETSDK) true true dotnet-suggest diff --git a/src/System.CommandLine.Tests/System.CommandLine.Tests.csproj b/src/System.CommandLine.Tests/System.CommandLine.Tests.csproj index c907e77ac2..3acc3cd6ad 100644 --- a/src/System.CommandLine.Tests/System.CommandLine.Tests.csproj +++ b/src/System.CommandLine.Tests/System.CommandLine.Tests.csproj @@ -1,6 +1,6 @@  - net7.0 + $(TargetFrameworkForNETSDK) $(TargetFrameworks);net462 false diff --git a/src/System.CommandLine.Tests/TestApps/NativeAOT/NativeAOT.csproj b/src/System.CommandLine.Tests/TestApps/NativeAOT/NativeAOT.csproj index e37a0569f1..cc306fea0d 100644 --- a/src/System.CommandLine.Tests/TestApps/NativeAOT/NativeAOT.csproj +++ b/src/System.CommandLine.Tests/TestApps/NativeAOT/NativeAOT.csproj @@ -2,13 +2,13 @@ Exe - net7.0 + $(TargetFrameworkForNETSDK) false - ..\..\..\System.CommandLine\bin\Release\net7.0\System.CommandLine.dll + ..\..\..\System.CommandLine\bin\Release\$(TargetFrameworkForNETSDK)\System.CommandLine.dll diff --git a/src/System.CommandLine.Tests/TestApps/Trimming/Trimming.csproj b/src/System.CommandLine.Tests/TestApps/Trimming/Trimming.csproj index b0b2fcd130..615b0764cf 100644 --- a/src/System.CommandLine.Tests/TestApps/Trimming/Trimming.csproj +++ b/src/System.CommandLine.Tests/TestApps/Trimming/Trimming.csproj @@ -2,7 +2,7 @@ Exe - net7.0 + $(TargetFrameworkForNETSDK) enable enable true @@ -10,7 +10,7 @@ - ..\..\..\System.CommandLine\bin\Release\net7.0\System.CommandLine.dll + ..\..\..\System.CommandLine\bin\Release\$(TargetFrameworkForNETSDK)\System.CommandLine.dll diff --git a/src/System.CommandLine/System.CommandLine.csproj b/src/System.CommandLine/System.CommandLine.csproj index 05d2847639..37115d707f 100644 --- a/src/System.CommandLine/System.CommandLine.csproj +++ b/src/System.CommandLine/System.CommandLine.csproj @@ -3,7 +3,7 @@ true System.CommandLine - net7.0;netstandard2.0 + $(TargetFrameworkForNETSDK);netstandard2.0 enable true 10 @@ -18,7 +18,7 @@ true - + true true