From e5e0166951414044b4c251fc562bb8d40620ca1f Mon Sep 17 00:00:00 2001 From: dkanada Date: Sun, 5 Jan 2020 15:59:31 +0900 Subject: [PATCH 1/8] update dotnet version for ci --- .ci/azure-pipelines.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.ci/azure-pipelines.yml b/.ci/azure-pipelines.yml index 13cc67528f..6e6cd00587 100644 --- a/.ci/azure-pipelines.yml +++ b/.ci/azure-pipelines.yml @@ -66,6 +66,12 @@ jobs: overWrite: true # Optional flattenFolders: false # Optional + - task: UseDotNet@2 + displayName: Use Correct DotNet Version + inputs: + packageType: sdk + version: 3.1.100 + - task: DotNetCoreCLI@2 displayName: Publish inputs: From f1008ab58d1b7dc9139f31e0a60f15e4be96aa4f Mon Sep 17 00:00:00 2001 From: dkanada Date: Sun, 5 Jan 2020 16:01:42 +0900 Subject: [PATCH 2/8] update job names --- .ci/azure-pipelines.yml | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/.ci/azure-pipelines.yml b/.ci/azure-pipelines.yml index 6e6cd00587..9927536238 100644 --- a/.ci/azure-pipelines.yml +++ b/.ci/azure-pipelines.yml @@ -19,9 +19,9 @@ jobs: vmImage: ubuntu-latest strategy: matrix: - release: + Release: BuildConfiguration: Release - debug: + Debug: BuildConfiguration: Debug maxParallel: 2 steps: @@ -191,12 +191,12 @@ jobs: # #publishRunAttachments: true # Optional - job: main_build_win - displayName: Main Build Windows + displayName: Publish Windows pool: vmImage: windows-latest strategy: matrix: - release: + Release: BuildConfiguration: Release maxParallel: 2 steps: @@ -373,5 +373,3 @@ jobs: script: 'dotnet tools/CompatibilityCheckerCoreCLI.dll current-release/$(AssemblyFileName) new-release/$(AssemblyFileName) --azure-pipelines' workingDirectory: $(System.ArtifactsDirectory) # Optional #failOnStderr: false # Optional - - From 303385dfa2799df9162aeb64294991b3bd4108c8 Mon Sep 17 00:00:00 2001 From: dkanada Date: Sun, 5 Jan 2020 16:08:19 +0900 Subject: [PATCH 3/8] remove unused parameters --- .ci/azure-pipelines.yml | 61 +---------------------------------------- 1 file changed, 1 insertion(+), 60 deletions(-) diff --git a/.ci/azure-pipelines.yml b/.ci/azure-pipelines.yml index 9927536238..7427190e61 100644 --- a/.ci/azure-pipelines.yml +++ b/.ci/azure-pipelines.yml @@ -141,54 +141,12 @@ jobs: !**\obj\** !**\xunit.runner.visualstudio.testadapter.dll !**\xunit.runner.visualstudio.dotnetcore.testadapter.dll - #testPlan: # Required when testSelector == TestPlan - #testSuite: # Required when testSelector == TestPlan - #testConfiguration: # Required when testSelector == TestPlan - #tcmTestRun: '$(test.RunId)' # Optional searchFolder: '$(System.DefaultWorkingDirectory)' - #testFiltercriteria: # Optional - #runOnlyImpactedTests: False # Optional - #runAllTestsAfterXBuilds: '50' # Optional - #uiTests: false # Optional - #vstestLocationMethod: 'version' # Optional. Options: version, location - #vsTestVersion: 'latest' # Optional. Options: latest, 16.0, 15.0, 14.0, toolsInstaller - #vstestLocation: # Optional - #runSettingsFile: # Optional - #overrideTestrunParameters: # Optional - #pathtoCustomTestAdapters: # Optional runInParallel: True # Optional runTestsInIsolation: True # Optional codeCoverageEnabled: True # Optional - #otherConsoleOptions: # Optional - #distributionBatchType: 'basedOnTestCases' # Optional. Options: basedOnTestCases, basedOnExecutionTime, basedOnAssembly - #batchingBasedOnAgentsOption: 'autoBatchSize' # Optional. Options: autoBatchSize, customBatchSize - #customBatchSizeValue: '10' # Required when distributionBatchType == BasedOnTestCases && BatchingBasedOnAgentsOption == CustomBatchSize - #batchingBasedOnExecutionTimeOption: 'autoBatchSize' # Optional. Options: autoBatchSize, customTimeBatchSize - #customRunTimePerBatchValue: '60' # Required when distributionBatchType == BasedOnExecutionTime && BatchingBasedOnExecutionTimeOption == CustomTimeBatchSize - #dontDistribute: False # Optional - #testRunTitle: # Optional - #platform: # Optional configuration: 'Debug' # Optional publishRunAttachments: true # Optional - #diagnosticsEnabled: false # Optional - #collectDumpOn: 'onAbortOnly' # Optional. Options: onAbortOnly, always, never - #rerunFailedTests: False # Optional - #rerunType: 'basedOnTestFailurePercentage' # Optional. Options: basedOnTestFailurePercentage, basedOnTestFailureCount - #rerunFailedThreshold: '30' # Optional - #rerunFailedTestCasesMaxLimit: '5' # Optional - #rerunMaxAttempts: '3' # Optional - - # - task: PublishTestResults@2 - # inputs: - # testResultsFormat: 'VSTest' # Options: JUnit, NUnit, VSTest, xUnit, cTest - # testResultsFiles: '**/*.trx' - # #searchFolder: '$(System.DefaultWorkingDirectory)' # Optional - # mergeTestResults: true # Optional - # #failTaskOnFailedTests: false # Optional - # #testRunTitle: # Optional - # #buildPlatform: # Optional - # #buildConfiguration: # Optional - # #publishRunAttachments: true # Optional - job: main_build_win displayName: Publish Windows @@ -252,11 +210,7 @@ jobs: targetType: 'filePath' # Optional. Options: filePath, inline filePath: ./deployment/windows/build-jellyfin.ps1 # Required when targetType == FilePath arguments: -InstallFFMPEG -InstallNSSM -MakeNSIS -InstallTrayApp -UXLocation $(Agent.TempDirectory)\jellyfin-ux -InstallLocation $(build.artifactstagingdirectory) - #script: '# Write your PowerShell commands here.Write-Host Hello World' # Required when targetType == Inline errorActionPreference: 'stop' # Optional. Options: stop, continue, silentlyContinue - #failOnStderr: false # Optional - #ignoreLASTEXITCODE: false # Optional - #pwsh: false # Optional workingDirectory: $(Build.SourcesDirectory) # Optional - task: CopyFiles@2 @@ -304,16 +258,9 @@ jobs: displayName: Download the New Assembly Build Artifact inputs: source: 'current' # Options: current, specific - #preferTriggeringPipeline: false # Optional - #tags: # Optional artifact: '$(NugetPackageName)' # Optional - #patterns: '**' # Optional path: '$(System.ArtifactsDirectory)/new-artifacts' - #project: # Required when source == Specific - #pipeline: # Required when source == Specific runVersion: 'latest' # Required when source == Specific. Options: latest, latestFromBranch, specific - #runBranch: 'refs/heads/master' # Required when source == Specific && runVersion == LatestFromBranch - #runId: # Required when source == Specific && runVersion == Specific - task: CopyFiles@2 displayName: Copy New Assembly to new-release folder @@ -329,16 +276,12 @@ jobs: displayName: Download the Reference Assembly Build Artifact inputs: source: 'specific' # Options: current, specific - #preferTriggeringPipeline: false # Optional - #tags: # Optional artifact: '$(NugetPackageName)' # Optional - #patterns: '**' # Optional path: '$(System.ArtifactsDirectory)/current-artifacts' project: '$(System.TeamProjectId)' # Required when source == Specific pipeline: '$(System.DefinitionId)' # Required when source == Specific runVersion: 'latestFromBranch' # Required when source == Specific. Options: latest, latestFromBranch, specific runBranch: 'refs/heads/$(System.PullRequest.TargetBranch)' # Required when source == Specific && runVersion == LatestFromBranch - #runId: # Required when source == Specific && runVersion == Specific - task: CopyFiles@2 displayName: Copy Reference Assembly to current-release folder @@ -356,7 +299,6 @@ jobs: connection: Jellyfin Release Download userRepository: EraYaN/dotnet-compatibility defaultVersionType: 'latest' # Options: latest, specificVersion, specificTag - #version: # Required when defaultVersionType != Latest itemPattern: '**-ci.zip' # Optional downloadPath: '$(System.ArtifactsDirectory)' @@ -371,5 +313,4 @@ jobs: displayName: Execute ABI compatibility check tool inputs: script: 'dotnet tools/CompatibilityCheckerCoreCLI.dll current-release/$(AssemblyFileName) new-release/$(AssemblyFileName) --azure-pipelines' - workingDirectory: $(System.ArtifactsDirectory) # Optional - #failOnStderr: false # Optional + workingDirectory: $(System.ArtifactsDirectory) From c7d5f35eb7e246191eb2d861eec8eb35be86a277 Mon Sep 17 00:00:00 2001 From: dkanada Date: Sun, 5 Jan 2020 16:32:24 +0900 Subject: [PATCH 4/8] update display names for some ci steps --- .ci/azure-pipelines.yml | 48 ++++++++++++++++++++--------------------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/.ci/azure-pipelines.yml b/.ci/azure-pipelines.yml index 7427190e61..6d2a0a42be 100644 --- a/.ci/azure-pipelines.yml +++ b/.ci/azure-pipelines.yml @@ -31,32 +31,32 @@ jobs: persistCredentials: true - task: CmdLine@2 - displayName: "Check out web" + displayName: "Clone Web Client (Master, Release, or Tag)" condition: and(succeeded(), or(contains(variables['Build.SourceBranch'], 'release'), contains(variables['Build.SourceBranch'], 'master')) ,eq(variables['BuildConfiguration'], 'Release'), in(variables['Build.Reason'], 'IndividualCI', 'BatchedCI', 'BuildCompletion')) inputs: script: 'git clone --single-branch --branch $(Build.SourceBranchName) --depth=1 https://github.com/jellyfin/jellyfin-web.git $(Agent.TempDirectory)/jellyfin-web' - task: CmdLine@2 - displayName: "Check out web (PR)" + displayName: "Clone Web Client (PR)" condition: and(succeeded(), or(contains(variables['System.PullRequest.TargetBranch'], 'release'), contains(variables['System.PullRequest.TargetBranch'], 'master')) ,eq(variables['BuildConfiguration'], 'Release'), in(variables['Build.Reason'], 'PullRequest')) inputs: script: 'git clone --single-branch --branch $(System.PullRequest.TargetBranch) --depth 1 https://github.com/jellyfin/jellyfin-web.git $(Agent.TempDirectory)/jellyfin-web' - task: NodeTool@0 - displayName: 'Install Node.js' + displayName: 'Install Node' condition: and(succeeded(), or(contains(variables['System.PullRequest.TargetBranch'], 'release'), contains(variables['System.PullRequest.TargetBranch'], 'master'), contains(variables['Build.SourceBranch'], 'release'), contains(variables['Build.SourceBranch'], 'master')) ,eq(variables['BuildConfiguration'], 'Release'), in(variables['Build.Reason'], 'PullRequest', 'IndividualCI', 'BatchedCI', 'BuildCompletion')) inputs: versionSpec: '10.x' - task: CmdLine@2 - displayName: "Build Web UI" + displayName: "Build Web Client" condition: and(succeeded(), or(contains(variables['System.PullRequest.TargetBranch'], 'release'), contains(variables['System.PullRequest.TargetBranch'], 'master'), contains(variables['Build.SourceBranch'], 'release'), contains(variables['Build.SourceBranch'], 'master')) ,eq(variables['BuildConfiguration'], 'Release'), in(variables['Build.Reason'], 'PullRequest', 'IndividualCI', 'BatchedCI', 'BuildCompletion')) inputs: script: yarn install workingDirectory: $(Agent.TempDirectory)/jellyfin-web - task: CopyFiles@2 - displayName: Copy the web UI + displayName: 'Copy Web Client' condition: and(succeeded(), or(contains(variables['System.PullRequest.TargetBranch'], 'release'), contains(variables['System.PullRequest.TargetBranch'], 'master'), contains(variables['Build.SourceBranch'], 'release'), contains(variables['Build.SourceBranch'], 'master')) ,eq(variables['BuildConfiguration'], 'Release'), in(variables['Build.Reason'], 'PullRequest', 'IndividualCI', 'BatchedCI', 'BuildCompletion')) inputs: sourceFolder: $(Agent.TempDirectory)/jellyfin-web/dist # Optional @@ -67,13 +67,13 @@ jobs: flattenFolders: false # Optional - task: UseDotNet@2 - displayName: Use Correct DotNet Version + displayName: 'Update DotNet' inputs: packageType: sdk version: 3.1.100 - task: DotNetCoreCLI@2 - displayName: Publish + displayName: 'Publish Server' inputs: command: publish publishWebProjects: false @@ -164,32 +164,32 @@ jobs: persistCredentials: true - task: CmdLine@2 - displayName: "Check out web (master, release or tag)" + displayName: "Clone Web Client (Master, Release, or Tag)" condition: and(succeeded(), or(contains(variables['Build.SourceBranch'], 'release'), contains(variables['Build.SourceBranch'], 'master'), contains(variables['Build.SourceBranch'], 'tag')) ,eq(variables['BuildConfiguration'], 'Release'), in(variables['Build.Reason'], 'IndividualCI', 'BatchedCI', 'BuildCompletion')) inputs: script: 'git clone --single-branch --branch $(Build.SourceBranchName) --depth=1 https://github.com/jellyfin/jellyfin-web.git $(Agent.TempDirectory)/jellyfin-web' - task: CmdLine@2 - displayName: "Check out web (PR)" + displayName: "Clone Web Client (PR)" condition: and(succeeded(), or(contains(variables['System.PullRequest.TargetBranch'], 'release'), contains(variables['System.PullRequest.TargetBranch'], 'master')) ,eq(variables['BuildConfiguration'], 'Release'), in(variables['Build.Reason'], 'PullRequest')) inputs: script: 'git clone --single-branch --branch $(System.PullRequest.TargetBranch) --depth 1 https://github.com/jellyfin/jellyfin-web.git $(Agent.TempDirectory)/jellyfin-web' - task: NodeTool@0 - displayName: 'Install Node.js' + displayName: 'Install Node' condition: and(succeeded(), or(contains(variables['System.PullRequest.TargetBranch'], 'release'), contains(variables['System.PullRequest.TargetBranch'], 'master'), contains(variables['Build.SourceBranch'], 'release'), contains(variables['Build.SourceBranch'], 'master')) ,eq(variables['BuildConfiguration'], 'Release'), in(variables['Build.Reason'], 'PullRequest', 'IndividualCI', 'BatchedCI', 'BuildCompletion')) inputs: versionSpec: '10.x' - task: CmdLine@2 - displayName: "Build Web UI" + displayName: "Build Web Client" condition: and(succeeded(), or(contains(variables['System.PullRequest.TargetBranch'], 'release'), contains(variables['System.PullRequest.TargetBranch'], 'master'), contains(variables['Build.SourceBranch'], 'release'), contains(variables['Build.SourceBranch'], 'master')) ,eq(variables['BuildConfiguration'], 'Release'), in(variables['Build.Reason'], 'PullRequest', 'IndividualCI', 'BatchedCI', 'BuildCompletion')) inputs: script: yarn install workingDirectory: $(Agent.TempDirectory)/jellyfin-web - task: CopyFiles@2 - displayName: Copy the web UI + displayName: 'Copy Web Client' condition: and(succeeded(), or(contains(variables['System.PullRequest.TargetBranch'], 'release'), contains(variables['System.PullRequest.TargetBranch'], 'master'), contains(variables['Build.SourceBranch'], 'release'), contains(variables['Build.SourceBranch'], 'master')) ,eq(variables['BuildConfiguration'], 'Release'), in(variables['Build.Reason'], 'PullRequest', 'IndividualCI', 'BatchedCI', 'BuildCompletion')) inputs: sourceFolder: $(Agent.TempDirectory)/jellyfin-web/dist # Optional @@ -200,12 +200,12 @@ jobs: flattenFolders: false # Optional - task: CmdLine@2 - displayName: Clone the UX repository + displayName: 'Clone UX Repository' inputs: script: git clone --depth=1 https://github.com/jellyfin/jellyfin-ux $(Agent.TempDirectory)\jellyfin-ux - task: PowerShell@2 - displayName: Build the NSIS Installer + displayName: 'Build NSIS Installer' inputs: targetType: 'filePath' # Optional. Options: filePath, inline filePath: ./deployment/windows/build-jellyfin.ps1 # Required when targetType == FilePath @@ -214,7 +214,7 @@ jobs: workingDirectory: $(Build.SourcesDirectory) # Optional - task: CopyFiles@2 - displayName: Copy the NSIS Installer to the artifact directory + displayName: 'Copy NSIS Installer' inputs: sourceFolder: $(Build.SourcesDirectory)/deployment/windows/ # Optional contents: 'jellyfin*.exe' @@ -224,7 +224,7 @@ jobs: flattenFolders: true # Optional - task: PublishPipelineArtifact@0 - displayName: 'Publish Setup Artifact' + displayName: 'Publish Artifact Setup' condition: and(eq(variables['BuildConfiguration'], 'Release'), succeeded()) inputs: targetPath: '$(build.artifactstagingdirectory)/setup' @@ -255,7 +255,7 @@ jobs: - checkout: none - task: DownloadPipelineArtifact@2 - displayName: Download the New Assembly Build Artifact + displayName: 'Download New Assembly Build Artifact' inputs: source: 'current' # Options: current, specific artifact: '$(NugetPackageName)' # Optional @@ -263,7 +263,7 @@ jobs: runVersion: 'latest' # Required when source == Specific. Options: latest, latestFromBranch, specific - task: CopyFiles@2 - displayName: Copy New Assembly to new-release folder + displayName: 'Copy New Assembly Build Artifact' inputs: sourceFolder: $(System.ArtifactsDirectory)/new-artifacts # Optional contents: '**/*.dll' @@ -273,7 +273,7 @@ jobs: flattenFolders: true # Optional - task: DownloadPipelineArtifact@2 - displayName: Download the Reference Assembly Build Artifact + displayName: 'Download Reference Assembly Build Artifact' inputs: source: 'specific' # Options: current, specific artifact: '$(NugetPackageName)' # Optional @@ -284,7 +284,7 @@ jobs: runBranch: 'refs/heads/$(System.PullRequest.TargetBranch)' # Required when source == Specific && runVersion == LatestFromBranch - task: CopyFiles@2 - displayName: Copy Reference Assembly to current-release folder + displayName: 'Copy Reference Assembly Build Artifact' inputs: sourceFolder: $(System.ArtifactsDirectory)/current-artifacts # Optional contents: '**/*.dll' @@ -294,7 +294,7 @@ jobs: flattenFolders: true # Optional - task: DownloadGitHubRelease@0 - displayName: Download ABI compatibility check tool from GitHub + displayName: 'Download ABI Compatibility Check Tool' inputs: connection: Jellyfin Release Download userRepository: EraYaN/dotnet-compatibility @@ -303,14 +303,14 @@ jobs: downloadPath: '$(System.ArtifactsDirectory)' - task: ExtractFiles@1 - displayName: Extract ABI compatibility check tool + displayName: 'Extract ABI Compatibility Check Tool' inputs: archiveFilePatterns: '$(System.ArtifactsDirectory)/*-ci.zip' destinationFolder: $(System.ArtifactsDirectory)/tools cleanDestinationFolder: true - task: CmdLine@2 - displayName: Execute ABI compatibility check tool + displayName: 'Execute ABI Compatibility Check Tool' inputs: script: 'dotnet tools/CompatibilityCheckerCoreCLI.dll current-release/$(AssemblyFileName) new-release/$(AssemblyFileName) --azure-pipelines' - workingDirectory: $(System.ArtifactsDirectory) + workingDirectory: $(System.ArtifactsDirectory) # Optional From d59912450819f6b9e8cb5b2e8eeb70c4d9de1465 Mon Sep 17 00:00:00 2001 From: dkanada Date: Sun, 5 Jan 2020 16:39:48 +0900 Subject: [PATCH 5/8] manually disable compatibility check --- .ci/azure-pipelines.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.ci/azure-pipelines.yml b/.ci/azure-pipelines.yml index 6d2a0a42be..fef2ecda96 100644 --- a/.ci/azure-pipelines.yml +++ b/.ci/azure-pipelines.yml @@ -235,7 +235,9 @@ jobs: pool: vmImage: ubuntu-latest dependsOn: main_build - condition: and(succeeded(), variables['System.PullRequest.PullRequestNumber']) # Only execute if the pullrequest numer is defined. (So not for normal CI builds) + # disabled until ABI is expected to remain unchanged + # only execute for pull requests + condition: and(eq(1, 2), succeeded(), variables['System.PullRequest.PullRequestNumber']) strategy: matrix: Naming: From 2ca7200a0526e5374f0b0e10d6f5d22965bacaa5 Mon Sep 17 00:00:00 2001 From: Erwin de Haan Date: Sun, 5 Jan 2020 19:24:24 +0100 Subject: [PATCH 6/8] Updated for v0.0.5 of the compat checker. --- .ci/azure-pipelines.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.ci/azure-pipelines.yml b/.ci/azure-pipelines.yml index fef2ecda96..ba9989e70f 100644 --- a/.ci/azure-pipelines.yml +++ b/.ci/azure-pipelines.yml @@ -311,8 +311,9 @@ jobs: destinationFolder: $(System.ArtifactsDirectory)/tools cleanDestinationFolder: true + # The `--warnings-only` switch will swallow the return code and not emit any errors. - task: CmdLine@2 displayName: 'Execute ABI Compatibility Check Tool' inputs: - script: 'dotnet tools/CompatibilityCheckerCoreCLI.dll current-release/$(AssemblyFileName) new-release/$(AssemblyFileName) --azure-pipelines' + script: 'dotnet tools/CompatibilityCheckerCLI.dll current-release/$(AssemblyFileName) new-release/$(AssemblyFileName) --azure-pipelines --warnings-only' workingDirectory: $(System.ArtifactsDirectory) # Optional From 65f65db8b9c7dcc2022ff6542a50481cb8d0cabf Mon Sep 17 00:00:00 2001 From: Erwin de Haan Date: Sun, 5 Jan 2020 19:25:33 +0100 Subject: [PATCH 7/8] Re-enable compat checks. --- .ci/azure-pipelines.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.ci/azure-pipelines.yml b/.ci/azure-pipelines.yml index ba9989e70f..e5d09b0aba 100644 --- a/.ci/azure-pipelines.yml +++ b/.ci/azure-pipelines.yml @@ -235,9 +235,8 @@ jobs: pool: vmImage: ubuntu-latest dependsOn: main_build - # disabled until ABI is expected to remain unchanged # only execute for pull requests - condition: and(eq(1, 2), succeeded(), variables['System.PullRequest.PullRequestNumber']) + condition: and(succeeded(), variables['System.PullRequest.PullRequestNumber']) strategy: matrix: Naming: From 21b78f44c8efe7eaa01430f23075d605c3d05356 Mon Sep 17 00:00:00 2001 From: Erwin de Haan Date: Sun, 5 Jan 2020 19:30:32 +0100 Subject: [PATCH 8/8] Add new dotnet version to compat stage as well. --- .ci/azure-pipelines.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.ci/azure-pipelines.yml b/.ci/azure-pipelines.yml index e5d09b0aba..143873266d 100644 --- a/.ci/azure-pipelines.yml +++ b/.ci/azure-pipelines.yml @@ -254,6 +254,12 @@ jobs: maxParallel: 2 steps: - checkout: none + + - task: UseDotNet@2 + displayName: 'Update DotNet' + inputs: + packageType: sdk + version: 3.1.100 - task: DownloadPipelineArtifact@2 displayName: 'Download New Assembly Build Artifact'