Skip to content

Commit e5861a7

Browse files
Update projects to net7.0 TargetFramework with shared property (#1803)
* Update projects to net7.0 TFM with shared property * Only enable trimming for .NET Core * Update ApiCompatibilityApprovalTests baseline (ordering change) Co-authored-by: MichaelSimons <[email protected]>
1 parent 4b60585 commit e5861a7

File tree

17 files changed

+40
-35
lines changed

17 files changed

+40
-35
lines changed

Directory.Build.props

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
<NoWarn Condition=" '$(DotnetBuildFromSource)' == 'true' ">$(NoWarn);CS8714;CS8765;CS8600;CS8601;CS8602;CS8603;CS8604</NoWarn>
1010
<PackageLicenseExpression>MIT</PackageLicenseExpression>
1111
<LangVersion>10.0</LangVersion>
12+
<TargetFrameworkForNETSDK>net7.0</TargetFrameworkForNETSDK>
1213
</PropertyGroup>
1314

1415
<PropertyGroup>

global.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
{
22
"tools": {
3-
"dotnet": "6.0.100",
3+
"dotnet": "7.0.100-preview.6.22352.1",
44
"runtimes": {
55
"dotnet": [
6-
"5.0.10"
6+
"5.0.17",
7+
"6.0.7"
78
]
89
},
9-
"xcopy-msbuild": "16.10.0-preview2"
10+
"xcopy-msbuild": "17.1.0"
1011
},
1112
"msbuild-sdks": {
1213
"Microsoft.DotNet.Arcade.Sdk": "7.0.0-beta.22168.2"

src/System.CommandLine.ApiCompatibility.Tests/ApiCompatibilityApprovalTests.System_CommandLine_NamingConventionBinder_api_is_not_changed.approved.txt

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,6 @@
33
public static System.Void AddModelBinder(this System.CommandLine.Binding.BindingContext bindingContext, ModelBinder binder)
44
public static ModelBinder GetOrCreateModelBinder(this System.CommandLine.Binding.BindingContext bindingContext, System.CommandLine.Binding.IValueDescriptor valueDescriptor)
55
public static class CommandHandler
6-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3>(Func<T1,T2,T3,System.Threading.Tasks.Task<System.Int32>> action)
7-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4>(Func<T1,T2,T3,T4,System.Threading.Tasks.Task<System.Int32>> action)
8-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5>(Func<T1,T2,T3,T4,T5,System.Threading.Tasks.Task<System.Int32>> action)
9-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6>(Func<T1,T2,T3,T4,T5,T6,System.Threading.Tasks.Task<System.Int32>> action)
10-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7>(Func<T1,T2,T3,T4,T5,T6,T7,System.Threading.Tasks.Task<System.Int32>> action)
11-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8>(Func<T1,T2,T3,T4,T5,T6,T7,T8,System.Threading.Tasks.Task<System.Int32>> action)
12-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,System.Threading.Tasks.Task<System.Int32>> action)
13-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,System.Threading.Tasks.Task<System.Int32>> action)
14-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,System.Threading.Tasks.Task<System.Int32>> action)
15-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,System.Threading.Tasks.Task<System.Int32>> action)
16-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,System.Threading.Tasks.Task<System.Int32>> action)
17-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,System.Threading.Tasks.Task<System.Int32>> action)
18-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,System.Threading.Tasks.Task<System.Int32>> action)
19-
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,System.Threading.Tasks.Task<System.Int32>> action)
206
public static System.CommandLine.ICommandHandler Create(System.Delegate delegate)
217
public static System.CommandLine.ICommandHandler Create<T>(Action<T> action)
228
public static System.CommandLine.ICommandHandler Create<T1, T2>(Action<T1,T2> action)
@@ -68,6 +54,20 @@
6854
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,System.Threading.Tasks.Task> action)
6955
public static System.CommandLine.ICommandHandler Create<T>(Func<T,System.Threading.Tasks.Task<System.Int32>> action)
7056
public static System.CommandLine.ICommandHandler Create<T1, T2>(Func<T1,T2,System.Threading.Tasks.Task<System.Int32>> action)
57+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3>(Func<T1,T2,T3,System.Threading.Tasks.Task<System.Int32>> action)
58+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4>(Func<T1,T2,T3,T4,System.Threading.Tasks.Task<System.Int32>> action)
59+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5>(Func<T1,T2,T3,T4,T5,System.Threading.Tasks.Task<System.Int32>> action)
60+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6>(Func<T1,T2,T3,T4,T5,T6,System.Threading.Tasks.Task<System.Int32>> action)
61+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7>(Func<T1,T2,T3,T4,T5,T6,T7,System.Threading.Tasks.Task<System.Int32>> action)
62+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8>(Func<T1,T2,T3,T4,T5,T6,T7,T8,System.Threading.Tasks.Task<System.Int32>> action)
63+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,System.Threading.Tasks.Task<System.Int32>> action)
64+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,System.Threading.Tasks.Task<System.Int32>> action)
65+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,System.Threading.Tasks.Task<System.Int32>> action)
66+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,System.Threading.Tasks.Task<System.Int32>> action)
67+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,System.Threading.Tasks.Task<System.Int32>> action)
68+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,System.Threading.Tasks.Task<System.Int32>> action)
69+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,System.Threading.Tasks.Task<System.Int32>> action)
70+
public static System.CommandLine.ICommandHandler Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16>(Func<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,System.Threading.Tasks.Task<System.Int32>> action)
7171
public static System.CommandLine.ICommandHandler Create(System.Reflection.MethodInfo method, System.Object target = null)
7272
public class ConstructorDescriptor, IMethodDescriptor
7373
public System.Collections.Generic.IReadOnlyList<ParameterDescriptor> ParameterDescriptors { get; }

src/System.CommandLine.ApiCompatibility.Tests/System.CommandLine.ApiCompatibility.Tests.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>net6.0</TargetFramework>
4+
<TargetFramework>$(TargetFrameworkForNETSDK)</TargetFramework>
55
<IsPackable>false</IsPackable>
66
</PropertyGroup>
77

src/System.CommandLine.Benchmarks/System.CommandLine.Benchmarks.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99
<UseSharedCompilation>false</UseSharedCompilation>
1010

1111
<!-- Supported target frameworks -->
12-
<TargetFrameworks Condition="'$(TargetFrameworks)' == '' AND '$(OS)' == 'Windows_NT'">net461;net5.0;net6.0;</TargetFrameworks>
13-
<TargetFrameworks Condition="'$(TargetFrameworks)' == ''">net5.0;net6.0;</TargetFrameworks>
12+
<TargetFrameworks Condition="'$(TargetFrameworks)' == '' AND '$(OS)' == 'Windows_NT'">net461;net5.0;net6.0;net7.0</TargetFrameworks>
13+
<TargetFrameworks Condition="'$(TargetFrameworks)' == ''">net5.0;net6.0;net7.0</TargetFrameworks>
1414

1515
<!-- This repo does not produce any libraries, therefore generating docs is disabled -->
1616
<GenerateDocumentationFile>False</GenerateDocumentationFile>

src/System.CommandLine.DragonFruit.Tests/System.CommandLine.DragonFruit.Tests.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
3-
<TargetFramework>net6.0</TargetFramework>
3+
<TargetFramework>$(TargetFrameworkForNETSDK)</TargetFramework>
44
<StartupObject>AutoGeneratedProgram</StartupObject>
55
<!-- Ensure that an XML doc file is emitted to supply command line help -->
66
<GenerateDocumentationFile>true</GenerateDocumentationFile>

src/System.CommandLine.Generator.Tests/System.CommandLine.Generator.Tests.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
3-
<TargetFrameworks>net6.0</TargetFrameworks>
3+
<TargetFrameworks>$(TargetFrameworkForNETSDK)</TargetFrameworks>
44
<TargetFrameworks Condition="'$(OS)' == 'Windows_NT'">$(TargetFrameworks);net462</TargetFrameworks>
55
<EmitCompilerGeneratedFiles>true</EmitCompilerGeneratedFiles>
66
<ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>

src/System.CommandLine.Hosting.Tests/System.CommandLine.Hosting.Tests.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>net6.0</TargetFrameworks>
4+
<TargetFrameworks>$(TargetFrameworkForNETSDK)</TargetFrameworks>
55
<TargetFrameworks Condition="'$(OS)' == 'Windows_NT'">$(TargetFrameworks);net462</TargetFrameworks>
66
<IsPackable>false</IsPackable>
77
</PropertyGroup>

src/System.CommandLine.NamingConventionBinder.Tests/System.CommandLine.NamingConventionBinder.Tests.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
3-
<TargetFrameworks>net6.0</TargetFrameworks>
3+
<TargetFrameworks>$(TargetFrameworkForNETSDK)</TargetFrameworks>
44
<TargetFrameworks Condition="'$(OS)' == 'Windows_NT'">$(TargetFrameworks);net462</TargetFrameworks>
55
<LangVersion>10</LangVersion>
66
</PropertyGroup>

src/System.CommandLine.Rendering.Tests/System.CommandLine.Rendering.Tests.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>net6.0</TargetFramework>
4+
<TargetFramework>$(TargetFrameworkForNETSDK)</TargetFramework>
55
<IsPackable>false</IsPackable>
66
</PropertyGroup>
77

0 commit comments

Comments
 (0)