@@ -6,11 +6,11 @@
|
|||||||
trigger:
|
trigger:
|
||||||
branches:
|
branches:
|
||||||
include:
|
include:
|
||||||
# Build all branches starting with 'ms-' This is useful when making and testing chanes made to this file
|
# Build all branches starting with 'ms-' This is useful when making and testing chanes made to this file
|
||||||
- ms-*
|
- ms-*
|
||||||
tags:
|
tags:
|
||||||
include:
|
include:
|
||||||
- '*'
|
- "*"
|
||||||
# pr:
|
# pr:
|
||||||
# - '*'
|
# - '*'
|
||||||
variables:
|
variables:
|
||||||
@@ -27,139 +27,138 @@ variables:
|
|||||||
# https://docs.microsoft.com/en-us/azure/devops/pipelines/library/service-endpoints?view=azure-devops&tabs=yaml#sep-github
|
# https://docs.microsoft.com/en-us/azure/devops/pipelines/library/service-endpoints?view=azure-devops&tabs=yaml#sep-github
|
||||||
xpcGitHubConnection: XPC-Azure
|
xpcGitHubConnection: XPC-Azure
|
||||||
|
|
||||||
|
|
||||||
stages:
|
stages:
|
||||||
- stage: Build
|
- stage: Build
|
||||||
jobs:
|
jobs:
|
||||||
- job: macOS
|
- job: macOS
|
||||||
pool:
|
pool:
|
||||||
vmImage: 'macos-latest'
|
vmImage: "macos-latest"
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- task: Xcode@5
|
- task: Xcode@5
|
||||||
inputs:
|
inputs:
|
||||||
actions: 'build'
|
actions: "build"
|
||||||
scheme: ''
|
scheme: ""
|
||||||
sdk: 'macosx10.14'
|
sdk: "macosx10.15"
|
||||||
configuration: 'Release'
|
configuration: "Release"
|
||||||
xcWorkspacePath: 'xpcPlugin/xpcPlugin.xcodeproj'
|
xcWorkspacePath: "xpcPlugin/xpcPlugin.xcodeproj"
|
||||||
xcodeVersion: 'default' # Options: 8, 9, 10, default, specifyPath
|
xcodeVersion: "default" # Options: 8, 9, 10, default, specifyPath
|
||||||
- task: PublishPipelineArtifact@0
|
- task: PublishPipelineArtifact@0
|
||||||
inputs:
|
inputs:
|
||||||
artifactName: '$(xpcArtifactNameMac)'
|
artifactName: "$(xpcArtifactNameMac)"
|
||||||
targetPath: '$(xpcBuildOutputPath)'
|
targetPath: "$(xpcBuildOutputPath)"
|
||||||
|
|
||||||
- job: Linux
|
- job: Linux
|
||||||
pool:
|
pool:
|
||||||
vmImage: 'ubuntu-latest'
|
vmImage: "ubuntu-latest"
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- script: |
|
- script: |
|
||||||
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
|
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install -y g++-5 mesa-common-dev g++-multilib g++-5-multilib
|
sudo apt-get install -y g++-5 mesa-common-dev g++-multilib g++-5-multilib
|
||||||
displayName: 'apt install'
|
displayName: "apt install"
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
cd xpcPlugin
|
cd xpcPlugin
|
||||||
cmake .
|
cmake .
|
||||||
make
|
make
|
||||||
displayName: 'make'
|
displayName: "make"
|
||||||
|
|
||||||
- task: PublishPipelineArtifact@0
|
- task: PublishPipelineArtifact@0
|
||||||
inputs:
|
inputs:
|
||||||
artifactName: 'xpc-linux'
|
artifactName: "xpc-linux"
|
||||||
targetPath: '$(xpcBuildOutputPath)'
|
targetPath: "$(xpcBuildOutputPath)"
|
||||||
|
|
||||||
- job: Windows
|
- job: Windows
|
||||||
pool:
|
pool:
|
||||||
vmImage: 'vs2017-win2016'
|
vmImage: "vs2017-win2016"
|
||||||
|
|
||||||
variables:
|
variables:
|
||||||
solution: 'xpcPlugin/xpcPlugin/xpcPlugin.sln'
|
solution: "xpcPlugin/xpcPlugin/xpcPlugin.sln"
|
||||||
buildPlatform: 'Win32|x64'
|
buildPlatform: "Win32|x64"
|
||||||
buildConfiguration: 'Release'
|
buildConfiguration: "Release"
|
||||||
appxPackageDir: '$(build.artifactStagingDirectory)\AppxPackages\\'
|
appxPackageDir: '$(build.artifactStagingDirectory)\AppxPackages\\'
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- task: NuGetToolInstaller@0
|
- task: NuGetToolInstaller@0
|
||||||
|
|
||||||
- task: NuGetCommand@2
|
- task: NuGetCommand@2
|
||||||
inputs:
|
inputs:
|
||||||
restoreSolution: '$(solution)'
|
restoreSolution: "$(solution)"
|
||||||
|
|
||||||
- task: VSBuild@1
|
- task: VSBuild@1
|
||||||
inputs:
|
inputs:
|
||||||
platform: 'Win32'
|
platform: "Win32"
|
||||||
solution: '$(solution)'
|
solution: "$(solution)"
|
||||||
configuration: '$(buildConfiguration)'
|
configuration: "$(buildConfiguration)"
|
||||||
msbuildArgs: '/p:AppxBundlePlatforms="$(buildPlatform)" /p:AppxPackageDir="$(appxPackageDir)" /p:AppxBundle=Always /p:UapAppxPackageBuildMode=StoreUpload'
|
msbuildArgs: '/p:AppxBundlePlatforms="$(buildPlatform)" /p:AppxPackageDir="$(appxPackageDir)" /p:AppxBundle=Always /p:UapAppxPackageBuildMode=StoreUpload'
|
||||||
|
|
||||||
- task: VSBuild@1
|
- task: VSBuild@1
|
||||||
inputs:
|
inputs:
|
||||||
platform: 'x64'
|
platform: "x64"
|
||||||
solution: '$(solution)'
|
solution: "$(solution)"
|
||||||
configuration: '$(buildConfiguration)'
|
configuration: "$(buildConfiguration)"
|
||||||
msbuildArgs: '/p:AppxBundlePlatforms="$(buildPlatform)" /p:AppxPackageDir="$(appxPackageDir)" /p:AppxBundle=Always /p:UapAppxPackageBuildMode=StoreUpload'
|
msbuildArgs: '/p:AppxBundlePlatforms="$(buildPlatform)" /p:AppxPackageDir="$(appxPackageDir)" /p:AppxBundle=Always /p:UapAppxPackageBuildMode=StoreUpload'
|
||||||
|
|
||||||
- task: Bash@3
|
- task: Bash@3
|
||||||
inputs:
|
inputs:
|
||||||
targetType: 'inline'
|
targetType: "inline"
|
||||||
script: |
|
script: |
|
||||||
rm $(xpcBuildOutputPath)/win.exp
|
rm $(xpcBuildOutputPath)/win.exp
|
||||||
rm $(xpcBuildOutputPath)/win.lib
|
rm $(xpcBuildOutputPath)/win.lib
|
||||||
rm $(xpcBuildOutputPath)/64/win.exp
|
rm $(xpcBuildOutputPath)/64/win.exp
|
||||||
rm $(xpcBuildOutputPath)/64/win.lib
|
rm $(xpcBuildOutputPath)/64/win.lib
|
||||||
|
|
||||||
- task: PublishPipelineArtifact@0
|
- task: PublishPipelineArtifact@0
|
||||||
inputs:
|
inputs:
|
||||||
artifactName: '$(xpcArtifactNameWindows)'
|
artifactName: "$(xpcArtifactNameWindows)"
|
||||||
targetPath: '$(xpcBuildOutputPath)'
|
targetPath: "$(xpcBuildOutputPath)"
|
||||||
|
|
||||||
- stage: Deploy
|
- stage: Deploy
|
||||||
jobs:
|
jobs:
|
||||||
- job: Package_Binaries
|
- job: Package_Binaries
|
||||||
displayName: 'Package Binaries'
|
displayName: "Package Binaries"
|
||||||
pool:
|
pool:
|
||||||
vmImage: 'ubuntu-latest'
|
vmImage: "ubuntu-latest"
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- task: DownloadPipelineArtifact@0
|
- task: DownloadPipelineArtifact@0
|
||||||
inputs:
|
inputs:
|
||||||
artifactName: '$(xpcArtifactNameMac)'
|
artifactName: "$(xpcArtifactNameMac)"
|
||||||
targetPath: $(System.DefaultWorkingDirectory)/$(xpcPackageName)
|
targetPath: $(System.DefaultWorkingDirectory)/$(xpcPackageName)
|
||||||
- task: DownloadPipelineArtifact@0
|
- task: DownloadPipelineArtifact@0
|
||||||
inputs:
|
inputs:
|
||||||
artifactName: '$(xpcArtifactNameLinux)'
|
artifactName: "$(xpcArtifactNameLinux)"
|
||||||
targetPath: $(System.DefaultWorkingDirectory)/$(xpcPackageName)
|
targetPath: $(System.DefaultWorkingDirectory)/$(xpcPackageName)
|
||||||
|
|
||||||
- task: DownloadPipelineArtifact@0
|
- task: DownloadPipelineArtifact@0
|
||||||
inputs:
|
inputs:
|
||||||
artifactName: '$(xpcArtifactNameWindows)'
|
artifactName: "$(xpcArtifactNameWindows)"
|
||||||
targetPath: $(System.DefaultWorkingDirectory)/$(xpcPackageName)
|
targetPath: $(System.DefaultWorkingDirectory)/$(xpcPackageName)
|
||||||
|
|
||||||
- task: PublishPipelineArtifact@0
|
- task: PublishPipelineArtifact@0
|
||||||
inputs:
|
inputs:
|
||||||
artifactName: '$(xpcPackageName)'
|
artifactName: "$(xpcPackageName)"
|
||||||
targetPath: $(System.DefaultWorkingDirectory)/$(xpcPackageName)
|
targetPath: $(System.DefaultWorkingDirectory)/$(xpcPackageName)
|
||||||
|
|
||||||
# Archive Files
|
# Archive Files
|
||||||
- task: ArchiveFiles@2
|
- task: ArchiveFiles@2
|
||||||
inputs:
|
inputs:
|
||||||
rootFolderOrFile: '$(System.DefaultWorkingDirectory)/$(xpcPackageName)'
|
rootFolderOrFile: "$(System.DefaultWorkingDirectory)/$(xpcPackageName)"
|
||||||
includeRootFolder: true
|
includeRootFolder: true
|
||||||
archiveType: 'zip'
|
archiveType: "zip"
|
||||||
archiveFile: '$(Build.ArtifactStagingDirectory)/$(xpcPackageName).zip'
|
archiveFile: "$(Build.ArtifactStagingDirectory)/$(xpcPackageName).zip"
|
||||||
|
|
||||||
# Uploads the .zip to GitHub and creates a new "Release" with the commit tag
|
# Uploads the .zip to GitHub and creates a new "Release" with the commit tag
|
||||||
# This tasks runs only on pushed tags
|
# This tasks runs only on pushed tags
|
||||||
- task: GitHubRelease@0
|
- task: GitHubRelease@0
|
||||||
inputs:
|
inputs:
|
||||||
gitHubConnection: '$(xpcGitHubConnection)'
|
gitHubConnection: "$(xpcGitHubConnection)"
|
||||||
repositoryName: '$(Build.Repository.Name)'
|
repositoryName: "$(Build.Repository.Name)"
|
||||||
action: 'create'
|
action: "create"
|
||||||
target: '$(Build.SourceVersion)'
|
target: "$(Build.SourceVersion)"
|
||||||
tagSource: 'auto'
|
tagSource: "auto"
|
||||||
tag: $(tagName)
|
tag: $(tagName)
|
||||||
assets: '$(Build.ArtifactStagingDirectory)/$(xpcPackageName).zip'
|
assets: "$(Build.ArtifactStagingDirectory)/$(xpcPackageName).zip"
|
||||||
isPreRelease: true
|
isPreRelease: true
|
||||||
|
|||||||
Reference in New Issue
Block a user