You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
97 lines
3.3 KiB
97 lines
3.3 KiB
5 years ago
|
parameters:
|
||
5 years ago
|
- name: Packages
|
||
|
type: object
|
||
|
default: {}
|
||
|
- name: LinuxImage
|
||
|
type: string
|
||
|
default: "ubuntu-latest"
|
||
|
- name: DotNetSdkVersion
|
||
|
type: string
|
||
|
default: 3.1.100
|
||
5 years ago
|
|
||
|
jobs:
|
||
|
- job: CompatibilityCheck
|
||
|
displayName: Compatibility Check
|
||
|
pool:
|
||
5 years ago
|
vmImage: "${{ parameters.LinuxImage }}"
|
||
5 years ago
|
# only execute for pull requests
|
||
|
condition: and(succeeded(), variables['System.PullRequest.PullRequestNumber'])
|
||
|
strategy:
|
||
|
matrix:
|
||
|
${{ each Package in parameters.Packages }}:
|
||
|
${{ Package.key }}:
|
||
|
NugetPackageName: ${{ Package.value.NugetPackageName }}
|
||
5 years ago
|
AssemblyFileName: ${{ Package.value.AssemblyFileName }}
|
||
|
maxParallel: 2
|
||
5 years ago
|
dependsOn: Build
|
||
5 years ago
|
steps:
|
||
|
- checkout: none
|
||
|
|
||
|
- task: UseDotNet@2
|
||
|
displayName: "Update DotNet"
|
||
|
inputs:
|
||
|
packageType: sdk
|
||
|
version: ${{ parameters.DotNetSdkVersion }}
|
||
|
|
||
|
- task: DownloadPipelineArtifact@2
|
||
|
displayName: "Download New Assembly Build Artifact"
|
||
|
inputs:
|
||
5 years ago
|
source: "current"
|
||
|
artifact: "$(NugetPackageName)"
|
||
5 years ago
|
path: "$(System.ArtifactsDirectory)/new-artifacts"
|
||
5 years ago
|
runVersion: "latest"
|
||
5 years ago
|
|
||
|
- task: CopyFiles@2
|
||
|
displayName: "Copy New Assembly Build Artifact"
|
||
|
inputs:
|
||
5 years ago
|
sourceFolder: $(System.ArtifactsDirectory)/new-artifacts
|
||
5 years ago
|
contents: "**/*.dll"
|
||
|
targetFolder: $(System.ArtifactsDirectory)/new-release
|
||
5 years ago
|
cleanTargetFolder: true
|
||
|
overWrite: true
|
||
|
flattenFolders: true
|
||
5 years ago
|
|
||
|
- task: DownloadPipelineArtifact@2
|
||
|
displayName: "Download Reference Assembly Build Artifact"
|
||
|
inputs:
|
||
5 years ago
|
source: "specific"
|
||
|
artifact: "$(NugetPackageName)"
|
||
5 years ago
|
path: "$(System.ArtifactsDirectory)/current-artifacts"
|
||
5 years ago
|
project: "$(System.TeamProjectId)"
|
||
|
pipeline: "$(System.DefinitionId)"
|
||
|
runVersion: "latestFromBranch"
|
||
|
runBranch: "refs/heads/$(System.PullRequest.TargetBranch)"
|
||
5 years ago
|
|
||
|
- task: CopyFiles@2
|
||
|
displayName: "Copy Reference Assembly Build Artifact"
|
||
|
inputs:
|
||
5 years ago
|
sourceFolder: $(System.ArtifactsDirectory)/current-artifacts
|
||
5 years ago
|
contents: "**/*.dll"
|
||
|
targetFolder: $(System.ArtifactsDirectory)/current-release
|
||
5 years ago
|
cleanTargetFolder: true
|
||
|
overWrite: true
|
||
|
flattenFolders: true
|
||
5 years ago
|
|
||
|
- task: DownloadGitHubRelease@0
|
||
|
displayName: "Download ABI Compatibility Check Tool"
|
||
|
inputs:
|
||
|
connection: Jellyfin Release Download
|
||
|
userRepository: EraYaN/dotnet-compatibility
|
||
5 years ago
|
defaultVersionType: "latest"
|
||
|
itemPattern: "**-ci.zip"
|
||
5 years ago
|
downloadPath: "$(System.ArtifactsDirectory)"
|
||
|
|
||
|
- task: ExtractFiles@1
|
||
|
displayName: "Extract ABI Compatibility Check Tool"
|
||
|
inputs:
|
||
|
archiveFilePatterns: "$(System.ArtifactsDirectory)/*-ci.zip"
|
||
|
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/CompatibilityCheckerCLI.dll current-release/$(AssemblyFileName) new-release/$(AssemblyFileName) --azure-pipelines --warnings-only"
|
||
5 years ago
|
workingDirectory: $(System.ArtifactsDirectory)
|