diff --git a/.azure-pipelines.yml b/.azure-pipelines.yml index 2854ab770..a8652a9ce 100644 --- a/.azure-pipelines.yml +++ b/.azure-pipelines.yml @@ -63,9 +63,9 @@ jobs: Linux: BuildName: 'Linux' ImageName: 'ubuntu-latest' - # macOS: - # BuildName: 'macOS' - # ImageName: 'macOS-latest' + macOS: + BuildName: 'macOS' + ImageName: 'macOS-latest' pool: vmImage: $(ImageName) steps: diff --git a/.config/dotnet-tools.json b/.config/dotnet-tools.json index 03fe9db99..66a687c6d 100644 --- a/.config/dotnet-tools.json +++ b/.config/dotnet-tools.json @@ -21,7 +21,7 @@ ] }, "nuke.globaltool": { - "version": "6.0.3", + "version": "6.2.1", "commands": [ "nuke" ] diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d1b7282c7..6c952a261 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -75,10 +75,7 @@ jobs: strategy: fail-fast: false matrix: - os: - # - macOS-latest - - windows-latest - - ubuntu-latest + os: [macOS-latest, windows-latest, ubuntu-latest] runs-on: ${{ matrix.os }} steps: - name: Checkout diff --git a/sample/SampleServer/SampleServer.csproj b/sample/SampleServer/SampleServer.csproj index c53281cd5..c7a131ab7 100644 --- a/sample/SampleServer/SampleServer.csproj +++ b/sample/SampleServer/SampleServer.csproj @@ -3,7 +3,7 @@ Exe false - netcoreapp3.1 + net6.0 win7-x64 latest diff --git a/src/JsonRpc.Generators/Records.cs b/src/JsonRpc.Generators/Records.cs index 66cef4915..8682d81e7 100644 --- a/src/JsonRpc.Generators/Records.cs +++ b/src/JsonRpc.Generators/Records.cs @@ -1,6 +1,8 @@ #pragma warning disable MA0048 // File name must match type name -#define INTERNAL_RECORD_ATTRIBUTES -#if NETSTANDARD2_0 || NETSTANDARD2_1 || NETCOREAPP2_0 || NETCOREAPP2_1 || NETCOREAPP2_2 || NET45 || NET451 || NET452 || NET6 || NET461 || NET462 || NET47 || NET471 || NET472 || NET48 +#if NET5_0_OR_GREATER +[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.CompilerServices.IsExternalInit))] +#else + using System.ComponentModel; // ReSharper disable once CheckNamespace @@ -11,12 +13,7 @@ namespace System.Runtime.CompilerServices /// This class should not be used by developers in source code. /// [EditorBrowsable(EditorBrowsableState.Never)] -#if INTERNAL_RECORD_ATTRIBUTES - internal -#else - public -#endif - static class IsExternalInit + internal static class IsExternalInit { } } diff --git a/src/JsonRpc/Nullable/Records.cs b/src/JsonRpc/Nullable/Records.cs index 207d2246e..8682d81e7 100644 --- a/src/JsonRpc/Nullable/Records.cs +++ b/src/JsonRpc/Nullable/Records.cs @@ -1,6 +1,8 @@ #pragma warning disable MA0048 // File name must match type name -#define INTERNAL_RECORD_ATTRIBUTES -#if NETSTANDARD || NETCOREAPP +#if NET5_0_OR_GREATER +[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.CompilerServices.IsExternalInit))] +#else + using System.ComponentModel; // ReSharper disable once CheckNamespace @@ -11,12 +13,7 @@ namespace System.Runtime.CompilerServices /// This class should not be used by developers in source code. /// [EditorBrowsable(EditorBrowsableState.Never)] -#if INTERNAL_RECORD_ATTRIBUTES - internal -#else - public -#endif - static class IsExternalInit + internal static class IsExternalInit { } } diff --git a/test/Client.Tests/Client.Tests.csproj b/test/Client.Tests/Client.Tests.csproj index 07ae8a6c0..190ea9ba0 100644 --- a/test/Client.Tests/Client.Tests.csproj +++ b/test/Client.Tests/Client.Tests.csproj @@ -1,7 +1,7 @@ - netcoreapp3.1;net6.0 + net6.0 OmniSharp.Extensions.LanguageClient.Tests OmniSharp.Extensions.LanguageServer.Client.Tests diff --git a/test/Dap.Tests/Dap.Tests.csproj b/test/Dap.Tests/Dap.Tests.csproj index e61abe1ff..68e5f8284 100644 --- a/test/Dap.Tests/Dap.Tests.csproj +++ b/test/Dap.Tests/Dap.Tests.csproj @@ -1,6 +1,6 @@  - netcoreapp3.1;net6.0 + net6.0 true AnyCPU @@ -16,6 +16,6 @@ - + diff --git a/test/Dap.Tests/Records.cs b/test/Dap.Tests/Records.cs deleted file mode 100644 index 207d2246e..000000000 --- a/test/Dap.Tests/Records.cs +++ /dev/null @@ -1,23 +0,0 @@ -#pragma warning disable MA0048 // File name must match type name -#define INTERNAL_RECORD_ATTRIBUTES -#if NETSTANDARD || NETCOREAPP -using System.ComponentModel; - -// ReSharper disable once CheckNamespace -namespace System.Runtime.CompilerServices -{ - /// - /// Reserved to be used by the compiler for tracking metadata. - /// This class should not be used by developers in source code. - /// - [EditorBrowsable(EditorBrowsableState.Never)] -#if INTERNAL_RECORD_ATTRIBUTES - internal -#else - public -#endif - static class IsExternalInit - { - } -} -#endif diff --git a/test/Generation.Tests/Generation.Tests.csproj b/test/Generation.Tests/Generation.Tests.csproj index 8f8f18ef0..eef43b102 100644 --- a/test/Generation.Tests/Generation.Tests.csproj +++ b/test/Generation.Tests/Generation.Tests.csproj @@ -1,6 +1,6 @@ - netcoreapp3.1;net6.0 + net6.0 true AnyCPU diff --git a/test/Generation.Tests/Records.cs b/test/Generation.Tests/Records.cs deleted file mode 100644 index 207d2246e..000000000 --- a/test/Generation.Tests/Records.cs +++ /dev/null @@ -1,23 +0,0 @@ -#pragma warning disable MA0048 // File name must match type name -#define INTERNAL_RECORD_ATTRIBUTES -#if NETSTANDARD || NETCOREAPP -using System.ComponentModel; - -// ReSharper disable once CheckNamespace -namespace System.Runtime.CompilerServices -{ - /// - /// Reserved to be used by the compiler for tracking metadata. - /// This class should not be used by developers in source code. - /// - [EditorBrowsable(EditorBrowsableState.Never)] -#if INTERNAL_RECORD_ATTRIBUTES - internal -#else - public -#endif - static class IsExternalInit - { - } -} -#endif diff --git a/test/JsonRpc.Tests/JsonRpc.Tests.csproj b/test/JsonRpc.Tests/JsonRpc.Tests.csproj index 163f47307..315c78b25 100644 --- a/test/JsonRpc.Tests/JsonRpc.Tests.csproj +++ b/test/JsonRpc.Tests/JsonRpc.Tests.csproj @@ -1,6 +1,6 @@ - netcoreapp3.1;net6.0 + net6.0 true AnyCPU diff --git a/test/Lsp.Integration.Tests/Lsp.Integration.Tests.csproj b/test/Lsp.Integration.Tests/Lsp.Integration.Tests.csproj index fcb489822..4d655de2e 100644 --- a/test/Lsp.Integration.Tests/Lsp.Integration.Tests.csproj +++ b/test/Lsp.Integration.Tests/Lsp.Integration.Tests.csproj @@ -1,6 +1,6 @@  - net6.0;netcoreapp3.1;net6.0 + net6.0 true AnyCPU diff --git a/test/Lsp.Integration.Tests/Records.cs b/test/Lsp.Integration.Tests/Records.cs deleted file mode 100644 index 207d2246e..000000000 --- a/test/Lsp.Integration.Tests/Records.cs +++ /dev/null @@ -1,23 +0,0 @@ -#pragma warning disable MA0048 // File name must match type name -#define INTERNAL_RECORD_ATTRIBUTES -#if NETSTANDARD || NETCOREAPP -using System.ComponentModel; - -// ReSharper disable once CheckNamespace -namespace System.Runtime.CompilerServices -{ - /// - /// Reserved to be used by the compiler for tracking metadata. - /// This class should not be used by developers in source code. - /// - [EditorBrowsable(EditorBrowsableState.Never)] -#if INTERNAL_RECORD_ATTRIBUTES - internal -#else - public -#endif - static class IsExternalInit - { - } -} -#endif diff --git a/test/Lsp.Tests/Lsp.Tests.csproj b/test/Lsp.Tests/Lsp.Tests.csproj index fcb489822..4d655de2e 100644 --- a/test/Lsp.Tests/Lsp.Tests.csproj +++ b/test/Lsp.Tests/Lsp.Tests.csproj @@ -1,6 +1,6 @@  - net6.0;netcoreapp3.1;net6.0 + net6.0 true AnyCPU diff --git a/test/Lsp.Tests/Records.cs b/test/Lsp.Tests/Records.cs deleted file mode 100644 index 207d2246e..000000000 --- a/test/Lsp.Tests/Records.cs +++ /dev/null @@ -1,23 +0,0 @@ -#pragma warning disable MA0048 // File name must match type name -#define INTERNAL_RECORD_ATTRIBUTES -#if NETSTANDARD || NETCOREAPP -using System.ComponentModel; - -// ReSharper disable once CheckNamespace -namespace System.Runtime.CompilerServices -{ - /// - /// Reserved to be used by the compiler for tracking metadata. - /// This class should not be used by developers in source code. - /// - [EditorBrowsable(EditorBrowsableState.Never)] -#if INTERNAL_RECORD_ATTRIBUTES - internal -#else - public -#endif - static class IsExternalInit - { - } -} -#endif