From 8da53ae6aac13b017fb4d08692cb42f94feb9ca3 Mon Sep 17 00:00:00 2001 From: ta264 Date: Mon, 9 Dec 2019 21:59:39 +0000 Subject: [PATCH] New: Bump to .NET Core 3.1 --- azure-pipelines.yml | 54 +++++++++---------- build.sh | 22 ++++---- package.json | 2 +- src/Directory.Build.props | 2 +- src/Lidarr.Api.V1/Lidarr.Api.V1.csproj | 10 ++-- src/Lidarr.Http/Lidarr.Http.csproj | 8 +-- src/NzbDrone.Api.Test/Lidarr.Api.Test.csproj | 6 +-- .../Lidarr.Automation.Test.csproj | 6 +-- .../Lidarr.Common.Test.csproj | 6 +-- .../Composition/ContainerBuilderBase.cs | 6 +-- .../EnvironmentInfo/PlatformInfo.cs | 4 +- .../EnvironmentInfo/RuntimeInfo.cs | 4 +- .../Extensions/DictionaryExtensions.cs | 2 +- src/NzbDrone.Common/Lidarr.Common.csproj | 18 +++---- src/NzbDrone.Console/Lidarr.Console.csproj | 2 +- .../Lidarr.Core.Test.csproj | 12 ++--- src/NzbDrone.Core/Lidarr.Core.csproj | 20 +++---- .../Lidarr.Host.Test.csproj | 6 +-- src/NzbDrone.Host/Lidarr.Host.csproj | 10 ++-- .../WebHost/Middleware/SignalRMiddleware.cs | 2 +- .../WebHost/WebHostController.cs | 4 +- .../Lidarr.Integration.Test.csproj | 8 +-- .../Lidarr.Libraries.Test.csproj | 6 +-- .../Lidarr.Mono.Test.csproj | 6 +-- src/NzbDrone.Mono/Lidarr.Mono.csproj | 8 +-- src/NzbDrone.SignalR/Lidarr.SignalR.csproj | 4 +- src/NzbDrone.Test.Common/AutoMoq/AutoMoqer.cs | 2 +- .../Lidarr.Test.Common.csproj | 14 ++--- src/NzbDrone.Test.Common/NzbDroneRunner.cs | 2 +- .../Lidarr.Test.Dummy.csproj | 2 +- .../Lidarr.Update.Test.csproj | 6 +-- src/NzbDrone.Update/Lidarr.Update.csproj | 4 +- .../Lidarr.Windows.Test.csproj | 6 +-- src/NzbDrone.Windows/Lidarr.Windows.csproj | 6 +-- src/NzbDrone/Lidarr.csproj | 4 +- src/NzbDrone/SysTray/SysTrayApp.cs | 10 ++-- .../ServiceInstall/ServiceInstall.csproj | 6 +-- .../ServiceUninstall/ServiceUninstall.csproj | 6 +-- yarn.lock | 8 +-- 39 files changed, 156 insertions(+), 158 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index b55a05779..8d6a2a4a8 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -12,7 +12,7 @@ variables: lidarrVersion: '$(majorVersion).$(minorVersion)' buildName: '$(Build.SourceBranchName).$(lidarrVersion)' sentryOrg: 'lidarr' - dotnetVersion: '3.0.100' + dotnetVersion: '3.1.100' trigger: branches: @@ -51,10 +51,9 @@ stages: submodules: true fetchDepth: 1 - task: UseDotNet@2 - displayName: 'Install .net core 3.0' + displayName: 'Install .net core' inputs: version: $(dotnetVersion) - condition: ne(variables['osName'], 'Windows') - bash: ./build.sh --backend displayName: Build Lidarr Backend - bash: | @@ -67,7 +66,7 @@ stages: artifact: '$(osName)Backend' displayName: Publish Backend condition: and(succeeded(), eq(variables['osName'], 'Windows')) - - publish: '$(testsFolder)/netcoreapp3.0/win-x64/publish' + - publish: '$(testsFolder)/netcoreapp3.1/win-x64/publish' artifact: WindowsCoreTests displayName: Publish Windows Test Package condition: and(succeeded(), eq(variables['osName'], 'Windows')) @@ -75,11 +74,11 @@ stages: artifact: LinuxTests displayName: Publish Linux Test Package condition: and(succeeded(), eq(variables['osName'], 'Windows')) - - publish: '$(testsFolder)/netcoreapp3.0/linux-x64/publish' + - publish: '$(testsFolder)/netcoreapp3.1/linux-x64/publish' artifact: LinuxCoreTests displayName: Publish Linux Test Package condition: and(succeeded(), eq(variables['osName'], 'Windows')) - - publish: '$(testsFolder)/netcoreapp3.0/osx-x64/publish' + - publish: '$(testsFolder)/netcoreapp3.1/osx-x64/publish' artifact: MacCoreTests displayName: Publish MacOS Test Package condition: and(succeeded(), eq(variables['osName'], 'Windows')) @@ -147,8 +146,8 @@ stages: - bash: ./build.sh --packages displayName: Create Packages - bash: | - setup/inno/ISCC.exe setup/lidarr.iss //DFramework=netcoreapp3.0 - cp setup/output/Lidarr.*windows.netcoreapp3.0.exe ${BUILD_ARTIFACTSTAGINGDIRECTORY}/Lidarr.${BUILDNAME}.windows-core-x64-installer.exe + setup/inno/ISCC.exe setup/lidarr.iss //DFramework=netcoreapp3.1 + cp setup/output/Lidarr.*windows.netcoreapp3.1.exe ${BUILD_ARTIFACTSTAGINGDIRECTORY}/Lidarr.${BUILDNAME}.windows-core-x64-installer.exe displayName: Create .NET Core Windows installer - publish: $(Build.ArtifactStagingDirectory) artifact: 'WindowsInstaller' @@ -191,14 +190,14 @@ stages: archiveFile: '$(Build.ArtifactStagingDirectory)/Lidarr.$(buildName).windows-core-x64.zip' archiveType: 'zip' includeRootFolder: false - rootFolderOrFile: $(artifactsFolder)/windows/netcoreapp3.0 + rootFolderOrFile: $(artifactsFolder)/windows/netcoreapp3.1 - task: ArchiveFiles@2 displayName: Create MacOS Core app inputs: archiveFile: '$(Build.ArtifactStagingDirectory)/Lidarr.$(buildName).osx-app-core-x64.zip' archiveType: 'zip' includeRootFolder: false - rootFolderOrFile: $(artifactsFolder)/macos-app/netcoreapp3.0 + rootFolderOrFile: $(artifactsFolder)/macos-app/netcoreapp3.1 - task: ArchiveFiles@2 displayName: Create MacOS Core tar inputs: @@ -206,7 +205,7 @@ stages: archiveType: 'tar' tarCompression: 'gz' includeRootFolder: false - rootFolderOrFile: $(artifactsFolder)/macos/netcoreapp3.0 + rootFolderOrFile: $(artifactsFolder)/macos/netcoreapp3.1 - task: ArchiveFiles@2 displayName: Create Linux Mono tar inputs: @@ -222,7 +221,7 @@ stages: archiveType: 'tar' tarCompression: 'gz' includeRootFolder: false - rootFolderOrFile: $(artifactsFolder)/linux-x64/netcoreapp3.0 + rootFolderOrFile: $(artifactsFolder)/linux-x64/netcoreapp3.1 - task: ArchiveFiles@2 displayName: Create ARM32 Core tar inputs: @@ -230,7 +229,7 @@ stages: archiveType: 'tar' tarCompression: 'gz' includeRootFolder: false - rootFolderOrFile: $(artifactsFolder)/linux-arm/netcoreapp3.0 + rootFolderOrFile: $(artifactsFolder)/linux-arm/netcoreapp3.1 - task: ArchiveFiles@2 displayName: Create Linux Core tar inputs: @@ -238,7 +237,7 @@ stages: archiveType: 'tar' tarCompression: 'gz' includeRootFolder: false - rootFolderOrFile: $(artifactsFolder)/linux-arm64/netcoreapp3.0 + rootFolderOrFile: $(artifactsFolder)/linux-arm64/netcoreapp3.1 - publish: $(Build.ArtifactStagingDirectory) artifact: 'Packages' displayName: Publish Packages @@ -294,10 +293,9 @@ stages: steps: - checkout: none - task: UseDotNet@2 - displayName: 'Install .net core 3.0' + displayName: 'Install .net core' inputs: version: $(dotnetVersion) - condition: ne(variables['osName'], 'Windows') - task: DownloadPipelineArtifact@2 displayName: Download Test Artifact inputs: @@ -371,10 +369,9 @@ stages: - bash: mono --version displayName: Check Mono version - task: UseDotNet@2 - displayName: 'Install .net core 3.0' + displayName: 'Install .net core' inputs: version: $(dotnetVersion) - condition: ne(variables['osName'], 'Windows') - checkout: none - task: DownloadPipelineArtifact@2 displayName: Download Test Artifact @@ -434,10 +431,9 @@ stages: displayName: Set Mono Version condition: and(succeeded(), eq(variables['osName'], 'Mac')) - task: UseDotNet@2 - displayName: 'Install .net core 3.0' + displayName: 'Install .net core' inputs: version: $(dotnetVersion) - condition: ne(variables['osName'], 'Windows') - checkout: none - task: DownloadPipelineArtifact@2 displayName: Download Test Artifact @@ -509,10 +505,9 @@ stages: - bash: mono --version displayName: Check Mono version - task: UseDotNet@2 - displayName: 'Install .net core 3.0' + displayName: 'Install .net core' inputs: version: $(dotnetVersion) - condition: ne(variables['osName'], 'Windows') - checkout: none - task: DownloadPipelineArtifact@2 displayName: Download Test Artifact @@ -579,10 +574,9 @@ stages: steps: - task: UseDotNet@2 - displayName: 'Install .net core 3.0' + displayName: 'Install .net core' inputs: version: $(dotnetVersion) - condition: ne(variables['osName'], 'Windows') - checkout: none - task: DownloadPipelineArtifact@2 displayName: Download Test Artifact @@ -608,9 +602,9 @@ stages: displayName: Move Package Contents - bash: | if [[ $OSNAME == "Mac" ]]; then - url=https://github.com/mozilla/geckodriver/releases/download/v0.24.0/geckodriver-v0.24.0-macos.tar.gz + url=https://github.com/mozilla/geckodriver/releases/download/v0.26.0/geckodriver-v0.26.0-macos.tar.gz elif [[ $OSNAME == "Linux" ]]; then - url=https://github.com/mozilla/geckodriver/releases/download/v0.24.0/geckodriver-v0.24.0-linux64.tar.gz + url=https://github.com/mozilla/geckodriver/releases/download/v0.26.0/geckodriver-v0.26.0-linux64.tar.gz else echo "Unhandled OS" exit 1 @@ -692,6 +686,10 @@ stages: variables: disable.coverage.autogenerate: 'true' steps: + - task: UseDotNet@2 + displayName: 'Install .net core' + inputs: + version: $(dotnetVersion) - checkout: self # Need history for Sonar analysis submodules: true - powershell: Set-Service SCardSvr -StartupType Manual @@ -710,8 +708,8 @@ stages: sonar.cs.opencover.reportsPaths=$(Build.SourcesDirectory)/CoverageResults/**/coverage.opencover.xml sonar.cs.nunit.reportsPaths=$(Build.SourcesDirectory)/TestResult.xml - bash: | - ./build.sh --backend -f netcoreapp3.0 -r win-x64 - TEST_DIR=_tests/netcoreapp3.0/win-x64/publish/ ./test.sh Windows Unit Coverage + ./build.sh --backend -f netcoreapp3.1 -r win-x64 + TEST_DIR=_tests/netcoreapp3.1/win-x64/publish/ ./test.sh Windows Unit Coverage displayName: Coverage Unit Tests - task: SonarCloudAnalyze@1 displayName: Publish SonarCloud Results diff --git a/build.sh b/build.sh index 30c74986c..df7b56ce9 100755 --- a/build.sh +++ b/build.sh @@ -137,7 +137,7 @@ PackageLinux() echo "Adding Lidarr.Mono to UpdatePackage" cp $folder/Lidarr.Mono.* $folder/Lidarr.Update - if [ "$framework" = "netcoreapp3.0" ]; then + if [ "$framework" = "netcoreapp3.1" ]; then cp $folder/Mono.Posix.NETStandard.* $folder/Lidarr.Update cp $folder/libMonoPosixHelper.* $folder/Lidarr.Update fi @@ -169,7 +169,7 @@ PackageMacOS() echo "Adding Lidarr.Mono to UpdatePackage" cp $folder/Lidarr.Mono.* $folder/Lidarr.Update - if [ "$framework" = "netcoreapp3.0" ]; then + if [ "$framework" = "netcoreapp3.1" ]; then cp $folder/Mono.Posix.NETStandard.* $folder/Lidarr.Update cp $folder/libMonoPosixHelper.* $folder/Lidarr.Update fi @@ -254,7 +254,7 @@ PackageTests() # geckodriver.exe isn't copied by dotnet publish if [ "$runtime" = "win-x64" ]; then - curl -Lso gecko.zip "https://github.com/mozilla/geckodriver/releases/download/v0.24.0/geckodriver-v0.24.0-win64.zip" + curl -Lso gecko.zip "https://github.com/mozilla/geckodriver/releases/download/v0.26.0/geckodriver-v0.26.0-win64.zip" unzip -o gecko.zip cp geckodriver.exe "$testPackageFolder/$framework/win-x64/publish" fi @@ -338,9 +338,9 @@ then Build if [[ -z "$RID" || -z "$FRAMEWORK" ]]; then - PackageTests "netcoreapp3.0" "win-x64" - PackageTests "netcoreapp3.0" "linux-x64" - PackageTests "netcoreapp3.0" "osx-x64" + PackageTests "netcoreapp3.1" "win-x64" + PackageTests "netcoreapp3.1" "linux-x64" + PackageTests "netcoreapp3.1" "osx-x64" PackageTests "net462" "linux-x64" else PackageTests "$FRAMEWORK" "$RID" @@ -369,11 +369,11 @@ then if [[ -z "$RID" || -z "$FRAMEWORK" ]]; then - Package "netcoreapp3.0" "win-x64" - Package "netcoreapp3.0" "linux-x64" - Package "netcoreapp3.0" "linux-arm64" - Package "netcoreapp3.0" "linux-arm" - Package "netcoreapp3.0" "osx-x64" + Package "netcoreapp3.1" "win-x64" + Package "netcoreapp3.1" "linux-x64" + Package "netcoreapp3.1" "linux-arm64" + Package "netcoreapp3.1" "linux-arm" + Package "netcoreapp3.1" "osx-x64" Package "net462" "linux-x64" else Package "$FRAMEWORK" "$RID" diff --git a/package.json b/package.json index 11d67ab1b..f953b44e3 100644 --- a/package.json +++ b/package.json @@ -38,7 +38,7 @@ "@fortawesome/free-regular-svg-icons": "5.10.2", "@fortawesome/free-solid-svg-icons": "5.10.2", "@fortawesome/react-fontawesome": "0.1.4", - "@microsoft/signalr": "3.0.0", + "@microsoft/signalr": "3.1.0", "@sentry/browser": "5.6.3", "@sentry/integrations": "5.6.1", "ansi-colors": "4.1.1", diff --git a/src/Directory.Build.props b/src/Directory.Build.props index 1b7e14a07..2808c082b 100644 --- a/src/Directory.Build.props +++ b/src/Directory.Build.props @@ -86,7 +86,7 @@ - + all runtime; build; native; contentfiles; analyzers diff --git a/src/Lidarr.Api.V1/Lidarr.Api.V1.csproj b/src/Lidarr.Api.V1/Lidarr.Api.V1.csproj index fa7dbe8e9..acfe8daa5 100644 --- a/src/Lidarr.Api.V1/Lidarr.Api.V1.csproj +++ b/src/Lidarr.Api.V1/Lidarr.Api.V1.csproj @@ -1,6 +1,6 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 @@ -10,13 +10,13 @@ - + - - - + + + diff --git a/src/Lidarr.Http/Lidarr.Http.csproj b/src/Lidarr.Http/Lidarr.Http.csproj index 246994fa0..94a218708 100644 --- a/src/Lidarr.Http/Lidarr.Http.csproj +++ b/src/Lidarr.Http/Lidarr.Http.csproj @@ -1,14 +1,14 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + - - + + diff --git a/src/NzbDrone.Api.Test/Lidarr.Api.Test.csproj b/src/NzbDrone.Api.Test/Lidarr.Api.Test.csproj index 8e10eea94..55f72974d 100644 --- a/src/NzbDrone.Api.Test/Lidarr.Api.Test.csproj +++ b/src/NzbDrone.Api.Test/Lidarr.Api.Test.csproj @@ -1,15 +1,15 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + - + diff --git a/src/NzbDrone.Automation.Test/Lidarr.Automation.Test.csproj b/src/NzbDrone.Automation.Test/Lidarr.Automation.Test.csproj index ef6bb1850..3c5077743 100644 --- a/src/NzbDrone.Automation.Test/Lidarr.Automation.Test.csproj +++ b/src/NzbDrone.Automation.Test/Lidarr.Automation.Test.csproj @@ -1,13 +1,13 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + - + diff --git a/src/NzbDrone.Common.Test/Lidarr.Common.Test.csproj b/src/NzbDrone.Common.Test/Lidarr.Common.Test.csproj index b6104de09..b3b66510f 100644 --- a/src/NzbDrone.Common.Test/Lidarr.Common.Test.csproj +++ b/src/NzbDrone.Common.Test/Lidarr.Common.Test.csproj @@ -1,14 +1,14 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + - + diff --git a/src/NzbDrone.Common/Composition/ContainerBuilderBase.cs b/src/NzbDrone.Common/Composition/ContainerBuilderBase.cs index c23cd077f..998c38cc1 100644 --- a/src/NzbDrone.Common/Composition/ContainerBuilderBase.cs +++ b/src/NzbDrone.Common/Composition/ContainerBuilderBase.cs @@ -6,7 +6,7 @@ using NzbDrone.Common.EnvironmentInfo; using NzbDrone.Common.Messaging; using TinyIoC; -#if NETCOREAPP3_0 +#if NETCOREAPP using System.IO; using System.Runtime.Loader; using System.Runtime.InteropServices; @@ -27,7 +27,7 @@ namespace NzbDrone.Common.Composition assemblies.Add(OsInfo.IsWindows ? "Lidarr.Windows" : "Lidarr.Mono"); assemblies.Add("Lidarr.Common"); -#if !NETCOREAPP3_0 +#if !NETCOREAPP foreach (var assembly in assemblies) { _loadedTypes.AddRange(Assembly.Load(assembly).GetTypes()); @@ -49,7 +49,7 @@ namespace NzbDrone.Common.Composition Container.Register(args); } -#if NETCOREAPP3_0 +#if NETCOREAPP private static Assembly ContainerResolveEventHandler(object sender, ResolveEventArgs args) { var _resolver = new AssemblyDependencyResolver(args.RequestingAssembly.Location); diff --git a/src/NzbDrone.Common/EnvironmentInfo/PlatformInfo.cs b/src/NzbDrone.Common/EnvironmentInfo/PlatformInfo.cs index 85fdb2f8a..f13d6bbc3 100644 --- a/src/NzbDrone.Common/EnvironmentInfo/PlatformInfo.cs +++ b/src/NzbDrone.Common/EnvironmentInfo/PlatformInfo.cs @@ -27,9 +27,9 @@ namespace NzbDrone.Common.EnvironmentInfo static PlatformInfo() { -#if NETCOREAPP3_0 +#if NETCOREAPP _platform = PlatformType.NetCore; - _version = new Version("3.0"); + _version = Environment.Version; #else if (Type.GetType("Mono.Runtime") != null) { diff --git a/src/NzbDrone.Common/EnvironmentInfo/RuntimeInfo.cs b/src/NzbDrone.Common/EnvironmentInfo/RuntimeInfo.cs index bed249ea2..b919756c8 100644 --- a/src/NzbDrone.Common/EnvironmentInfo/RuntimeInfo.cs +++ b/src/NzbDrone.Common/EnvironmentInfo/RuntimeInfo.cs @@ -7,7 +7,7 @@ using System.ServiceProcess; using NLog; using NzbDrone.Common.Processes; -#if NETCOREAPP3_0 +#if NETCOREAPP using Microsoft.Extensions.Hosting.WindowsServices; #endif @@ -61,7 +61,7 @@ namespace NzbDrone.Common.EnvironmentInfo } } -#if !NETCOREAPP3_0 +#if !NETCOREAPP public static bool IsUserInteractive => Environment.UserInteractive; #else // Note that Environment.UserInteractive is always true on net core: https://stackoverflow.com/a/57325783 diff --git a/src/NzbDrone.Common/Extensions/DictionaryExtensions.cs b/src/NzbDrone.Common/Extensions/DictionaryExtensions.cs index 646e657aa..ec1d63f71 100644 --- a/src/NzbDrone.Common/Extensions/DictionaryExtensions.cs +++ b/src/NzbDrone.Common/Extensions/DictionaryExtensions.cs @@ -6,7 +6,7 @@ namespace NzbDrone.Common.Extensions { public static class DictionaryExtensions { -#if !NETCOREAPP3_0 +#if !NETCOREAPP public static TValue GetValueOrDefault(this IReadOnlyDictionary dictionary, TKey key, TValue defaultValue = default(TValue)) { TValue value; diff --git a/src/NzbDrone.Common/Lidarr.Common.csproj b/src/NzbDrone.Common/Lidarr.Common.csproj index 33eb2aaf7..8efb02007 100644 --- a/src/NzbDrone.Common/Lidarr.Common.csproj +++ b/src/NzbDrone.Common/Lidarr.Common.csproj @@ -1,23 +1,23 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - - + + - + - + - - - - + + + + diff --git a/src/NzbDrone.Console/Lidarr.Console.csproj b/src/NzbDrone.Console/Lidarr.Console.csproj index 52f785be5..9e0c5da02 100644 --- a/src/NzbDrone.Console/Lidarr.Console.csproj +++ b/src/NzbDrone.Console/Lidarr.Console.csproj @@ -1,7 +1,7 @@  Exe - net462;netcoreapp3.0 + net462;netcoreapp3.1 ..\NzbDrone.Host\NzbDrone.ico app.manifest diff --git a/src/NzbDrone.Core.Test/Lidarr.Core.Test.csproj b/src/NzbDrone.Core.Test/Lidarr.Core.Test.csproj index a8a8995dd..8dc55f1e0 100644 --- a/src/NzbDrone.Core.Test/Lidarr.Core.Test.csproj +++ b/src/NzbDrone.Core.Test/Lidarr.Core.Test.csproj @@ -1,18 +1,18 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + - + - + @@ -31,10 +31,10 @@ PreserveNewest - + - + diff --git a/src/NzbDrone.Core/Lidarr.Core.csproj b/src/NzbDrone.Core/Lidarr.Core.csproj index 5c76c2092..8b2b6fa92 100644 --- a/src/NzbDrone.Core/Lidarr.Core.csproj +++ b/src/NzbDrone.Core/Lidarr.Core.csproj @@ -1,21 +1,21 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - - + + - - - + + + - + - + @@ -36,10 +36,10 @@ Resources\Logo\64.png - + - + diff --git a/src/NzbDrone.Host.Test/Lidarr.Host.Test.csproj b/src/NzbDrone.Host.Test/Lidarr.Host.Test.csproj index f033a2aff..174cdda4a 100644 --- a/src/NzbDrone.Host.Test/Lidarr.Host.Test.csproj +++ b/src/NzbDrone.Host.Test/Lidarr.Host.Test.csproj @@ -1,14 +1,14 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + - + diff --git a/src/NzbDrone.Host/Lidarr.Host.csproj b/src/NzbDrone.Host/Lidarr.Host.csproj index d7d1c95c4..b04d3f68b 100644 --- a/src/NzbDrone.Host/Lidarr.Host.csproj +++ b/src/NzbDrone.Host/Lidarr.Host.csproj @@ -1,6 +1,6 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 Library @@ -9,12 +9,12 @@ - - - + + + - + diff --git a/src/NzbDrone.Host/WebHost/Middleware/SignalRMiddleware.cs b/src/NzbDrone.Host/WebHost/Middleware/SignalRMiddleware.cs index a31c1e3ce..1adae83e7 100644 --- a/src/NzbDrone.Host/WebHost/Middleware/SignalRMiddleware.cs +++ b/src/NzbDrone.Host/WebHost/Middleware/SignalRMiddleware.cs @@ -55,7 +55,7 @@ namespace NzbDrone.Host.Middleware } }); -#if NETCOREAPP3_0 +#if NETCOREAPP appBuilder.UseEndpoints(x => { x.MapHub(URL_BASE + "/signalr/messages"); diff --git a/src/NzbDrone.Host/WebHost/WebHostController.cs b/src/NzbDrone.Host/WebHost/WebHostController.cs index 718fb0cfb..5e0481369 100644 --- a/src/NzbDrone.Host/WebHost/WebHostController.cs +++ b/src/NzbDrone.Host/WebHost/WebHostController.cs @@ -89,7 +89,7 @@ namespace NzbDrone.Host { services .AddSignalR() -#if !NETCOREAPP3_0 +#if !NETCOREAPP .AddJsonProtocol( #else .AddNewtonsoftJsonProtocol( @@ -101,7 +101,7 @@ namespace NzbDrone.Host }) .Configure(app => { -#if NETCOREAPP3_0 +#if NETCOREAPP app.UseRouting(); #endif app.Properties["host.AppName"] = BuildInfo.AppName; diff --git a/src/NzbDrone.Integration.Test/Lidarr.Integration.Test.csproj b/src/NzbDrone.Integration.Test/Lidarr.Integration.Test.csproj index 162b53554..04359dbe5 100644 --- a/src/NzbDrone.Integration.Test/Lidarr.Integration.Test.csproj +++ b/src/NzbDrone.Integration.Test/Lidarr.Integration.Test.csproj @@ -1,10 +1,10 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 Library - + @@ -12,8 +12,8 @@ - - + + diff --git a/src/NzbDrone.Libraries.Test/Lidarr.Libraries.Test.csproj b/src/NzbDrone.Libraries.Test/Lidarr.Libraries.Test.csproj index 3bdd9a6ab..f37175988 100644 --- a/src/NzbDrone.Libraries.Test/Lidarr.Libraries.Test.csproj +++ b/src/NzbDrone.Libraries.Test/Lidarr.Libraries.Test.csproj @@ -1,14 +1,14 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + - + diff --git a/src/NzbDrone.Mono.Test/Lidarr.Mono.Test.csproj b/src/NzbDrone.Mono.Test/Lidarr.Mono.Test.csproj index c882fa8b0..2ac52b149 100644 --- a/src/NzbDrone.Mono.Test/Lidarr.Mono.Test.csproj +++ b/src/NzbDrone.Mono.Test/Lidarr.Mono.Test.csproj @@ -1,9 +1,9 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + @@ -15,7 +15,7 @@ The netstandard veresion here doesn't work in net framework See https://github.com/xamarin/XamarinComponents/issues/282 --> - + diff --git a/src/NzbDrone.Mono/Lidarr.Mono.csproj b/src/NzbDrone.Mono/Lidarr.Mono.csproj index 19a270fdc..300329c7d 100644 --- a/src/NzbDrone.Mono/Lidarr.Mono.csproj +++ b/src/NzbDrone.Mono/Lidarr.Mono.csproj @@ -1,10 +1,10 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - - + + @@ -13,7 +13,7 @@ The netstandard veresion here doesn't work in net framework See https://github.com/xamarin/XamarinComponents/issues/282 --> - + diff --git a/src/NzbDrone.SignalR/Lidarr.SignalR.csproj b/src/NzbDrone.SignalR/Lidarr.SignalR.csproj index a34df9c4e..bb147cb04 100644 --- a/src/NzbDrone.SignalR/Lidarr.SignalR.csproj +++ b/src/NzbDrone.SignalR/Lidarr.SignalR.csproj @@ -1,11 +1,11 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 Library - + diff --git a/src/NzbDrone.Test.Common/AutoMoq/AutoMoqer.cs b/src/NzbDrone.Test.Common/AutoMoq/AutoMoqer.cs index d63f07c60..05cdb6811 100644 --- a/src/NzbDrone.Test.Common/AutoMoq/AutoMoqer.cs +++ b/src/NzbDrone.Test.Common/AutoMoq/AutoMoqer.cs @@ -152,7 +152,7 @@ namespace NzbDrone.Test.Common.AutoMoq RegisterPlatformLibrary(container); AddTheAutoMockingContainerExtensionToTheContainer(container); -#if NETCOREAPP3_0 +#if NETCOREAPP ContainerBuilderBase.RegisterSQLiteResolver(); #endif } diff --git a/src/NzbDrone.Test.Common/Lidarr.Test.Common.csproj b/src/NzbDrone.Test.Common/Lidarr.Test.Common.csproj index 3f8c9211c..14a63b782 100644 --- a/src/NzbDrone.Test.Common/Lidarr.Test.Common.csproj +++ b/src/NzbDrone.Test.Common/Lidarr.Test.Common.csproj @@ -1,17 +1,17 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - - - - + + + + - - + + diff --git a/src/NzbDrone.Test.Common/NzbDroneRunner.cs b/src/NzbDrone.Test.Common/NzbDroneRunner.cs index 26535d0a3..8ebf5b1c1 100644 --- a/src/NzbDrone.Test.Common/NzbDroneRunner.cs +++ b/src/NzbDrone.Test.Common/NzbDroneRunner.cs @@ -50,7 +50,7 @@ namespace NzbDrone.Test.Common if (BuildInfo.IsDebug) { - var frameworkFolder = PlatformInfo.IsNetCore ? "netcoreapp3.0" : "net462"; + var frameworkFolder = PlatformInfo.IsNetCore ? "netcoreapp3.1" : "net462"; Start(Path.Combine(TestContext.CurrentContext.TestDirectory, "..", "..", "_output", frameworkFolder, lidarrConsoleExe)); } else diff --git a/src/NzbDrone.Test.Dummy/Lidarr.Test.Dummy.csproj b/src/NzbDrone.Test.Dummy/Lidarr.Test.Dummy.csproj index 55a744097..548383e0a 100644 --- a/src/NzbDrone.Test.Dummy/Lidarr.Test.Dummy.csproj +++ b/src/NzbDrone.Test.Dummy/Lidarr.Test.Dummy.csproj @@ -1,6 +1,6 @@  Exe - net462;netcoreapp3.0 + net462;netcoreapp3.1 diff --git a/src/NzbDrone.Update.Test/Lidarr.Update.Test.csproj b/src/NzbDrone.Update.Test/Lidarr.Update.Test.csproj index 67c19d920..84a4a1b93 100644 --- a/src/NzbDrone.Update.Test/Lidarr.Update.Test.csproj +++ b/src/NzbDrone.Update.Test/Lidarr.Update.Test.csproj @@ -1,14 +1,14 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + - + diff --git a/src/NzbDrone.Update/Lidarr.Update.csproj b/src/NzbDrone.Update/Lidarr.Update.csproj index a71c04eef..00bdb6252 100644 --- a/src/NzbDrone.Update/Lidarr.Update.csproj +++ b/src/NzbDrone.Update/Lidarr.Update.csproj @@ -1,10 +1,10 @@  WinExe - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + diff --git a/src/NzbDrone.Windows.Test/Lidarr.Windows.Test.csproj b/src/NzbDrone.Windows.Test/Lidarr.Windows.Test.csproj index 302cef1a9..884aeb29d 100644 --- a/src/NzbDrone.Windows.Test/Lidarr.Windows.Test.csproj +++ b/src/NzbDrone.Windows.Test/Lidarr.Windows.Test.csproj @@ -1,14 +1,14 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - + - + diff --git a/src/NzbDrone.Windows/Lidarr.Windows.csproj b/src/NzbDrone.Windows/Lidarr.Windows.csproj index aff5f065d..783c59ee0 100644 --- a/src/NzbDrone.Windows/Lidarr.Windows.csproj +++ b/src/NzbDrone.Windows/Lidarr.Windows.csproj @@ -1,10 +1,10 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 - - + + diff --git a/src/NzbDrone/Lidarr.csproj b/src/NzbDrone/Lidarr.csproj index da38debce..03065ca9e 100644 --- a/src/NzbDrone/Lidarr.csproj +++ b/src/NzbDrone/Lidarr.csproj @@ -1,7 +1,7 @@  WinExe - net462;netcoreapp3.0 + net462;netcoreapp3.1 win-x64 true ..\NzbDrone.Host\NzbDrone.ico @@ -9,7 +9,7 @@ true - + diff --git a/src/NzbDrone/SysTray/SysTrayApp.cs b/src/NzbDrone/SysTray/SysTrayApp.cs index 70af0b0ab..c98a54f54 100644 --- a/src/NzbDrone/SysTray/SysTrayApp.cs +++ b/src/NzbDrone/SysTray/SysTrayApp.cs @@ -20,7 +20,7 @@ namespace NzbDrone.SysTray private readonly IProcessProvider _processProvider; private readonly NotifyIcon _trayIcon = new NotifyIcon(); - private readonly ContextMenu _trayMenu = new ContextMenu(); + private readonly ContextMenuStrip _trayMenu = new ContextMenuStrip(); public SystemTrayApp(IBrowserService browserService, IRuntimeInfo runtimeInfo, IProcessProvider processProvider) { @@ -34,14 +34,14 @@ namespace NzbDrone.SysTray Application.ThreadException += OnThreadException; Application.ApplicationExit += OnApplicationExit; - _trayMenu.MenuItems.Add("Launch Browser", LaunchBrowser); - _trayMenu.MenuItems.Add("-"); - _trayMenu.MenuItems.Add("Exit", OnExit); + _trayMenu.Items.Add(new ToolStripMenuItem("Launch Browser", null, LaunchBrowser)); + _trayMenu.Items.Add(new ToolStripMenuItem("-")); + _trayMenu.Items.Add(new ToolStripMenuItem("Exit", null, OnExit)); _trayIcon.Text = string.Format("Lidarr - {0}", BuildInfo.Version); _trayIcon.Icon = Properties.Resources.NzbDroneIcon; - _trayIcon.ContextMenu = _trayMenu; + _trayIcon.ContextMenuStrip = _trayMenu; _trayIcon.Visible = true; _trayIcon.DoubleClick += LaunchBrowser; diff --git a/src/ServiceHelpers/ServiceInstall/ServiceInstall.csproj b/src/ServiceHelpers/ServiceInstall/ServiceInstall.csproj index 8a735f3bf..e45e49618 100644 --- a/src/ServiceHelpers/ServiceInstall/ServiceInstall.csproj +++ b/src/ServiceHelpers/ServiceInstall/ServiceInstall.csproj @@ -1,9 +1,9 @@  WinExe - net462;netcoreapp3.0 + net462;netcoreapp3.1 - - + + diff --git a/src/ServiceHelpers/ServiceUninstall/ServiceUninstall.csproj b/src/ServiceHelpers/ServiceUninstall/ServiceUninstall.csproj index 69ed0d676..10a25654c 100644 --- a/src/ServiceHelpers/ServiceUninstall/ServiceUninstall.csproj +++ b/src/ServiceHelpers/ServiceUninstall/ServiceUninstall.csproj @@ -1,9 +1,9 @@  WinExe - net462;netcoreapp3.0 + net462;netcoreapp3.1 - - + + diff --git a/yarn.lock b/yarn.lock index 344484abd..9c094ecd0 100644 --- a/yarn.lock +++ b/yarn.lock @@ -903,10 +903,10 @@ normalize-path "^2.0.1" through2 "^2.0.3" -"@microsoft/signalr@3.0.0": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@microsoft/signalr/-/signalr-3.0.0.tgz#df03564f900957db0a62469cad576eb573368c9d" - integrity sha512-M0KMWvJ62yZuizPxFLZakitJb4aOZkJH6epXTLvp5LednJZdzacRDxWT3La7Cexp1cHxVbldBFtc3jrdfwmtxw== +"@microsoft/signalr@3.1.0": + version "3.1.0" + resolved "https://registry.yarnpkg.com/@microsoft/signalr/-/signalr-3.1.0.tgz#2ed5ab78de1ae252d3c18504355ca74814c62284" + integrity sha512-ZAScxodI15jr1MF359jwelhrr/fkvCCTWUB5awRO+ibPyBvMS6KsSzWfN/AObc0EqvJPmYtjJgCBWR62nInlCg== dependencies: eventsource "^1.0.7" request "^2.88.0"