This repository has been archived by the owner on Jul 12, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 8
/
azure-pipelines.yml
75 lines (74 loc) · 2.37 KB
/
azure-pipelines.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
trigger:
- master
jobs:
- job: Nugetbuild
pool:
vmImage: 'windows-2019'
timeoutInMinutes: 240
steps:
- checkout: self
submodules: recursive
- task: CopyFiles@2
inputs:
targetFolder: '$(Build.StagingDirectory)\_'
- task: UseDotNet@2
displayName: 'Use dotnet sdk 3.x'
inputs:
version: 3.x
- task: DownloadBuildArtifacts@0
inputs:
buildType: 'specific' # Options: current, specific
project: 'mrtk_ros' # Required when source == Specific
pipeline: 141 # Required when source == Specific
buildVersionToDownload: 'latest' # Required when source == Specific# Options: latest, latestFromBranch, specific
artifactName: 'ros2vcpkg'
- script: |
mkdir c:\opt\vcpkg
7z x %System_ArtifactsDirectory%\ros2vcpkg\vcpkg.zip.001 -oc:\opt
displayName: Initialize vcpkg
- script: |
call inittree.cmd
call inittools.cmd /x64
displayName: Init Tree
continueOnError: true
workingDirectory: '$(Build.StagingDirectory)\_'
- script: |
pushd src
: BUGBUG need to build twice due to the dotnet generator
build.cmd /x64
popd
displayName: Build ROS2 Components x64 (Pass 0)
continueOnError: true
workingDirectory: '$(Build.StagingDirectory)\_'
- script: |
pushd src
: BUGBUG need to build twice due to the dotnet generator
build.cmd /x64
popd
displayName: Build ROS2 Components Unity (Pass 1)
continueOnError: false
workingDirectory: '$(Build.StagingDirectory)\_'
- task: PublishBuildArtifacts@1
inputs:
pathtoPublish: $(Build.StagingDirectory)\_\target\log
artifactName: 'ros2dotnet-log'
condition: always()
- task: NuGetCommand@2
displayName: 'NuGet pack x64'
inputs:
command: pack
basePath: $(Build.StagingDirectory)\_\nuget
packagesToPack: $(Build.StagingDirectory)\_\nuget\Microsoft.ROS.MRTK.Foxy.x64.nuspec
packDestination: '$(Build.ArtifactStagingDirectory)/nuget'
- task: PublishBuildArtifacts@1
displayName: 'NuGet publish x64'
inputs:
pathtoPublish: $(Build.ArtifactStagingDirectory)/nuget
artifactName: 'ros2dotnet-nuget-x64'
- task: NuGetCommand@2
displayName: 'NuGet push all'
inputs:
command: push
packagesToPush: '$(Build.ArtifactStagingDirectory)/nuget/*.nupkg'
publishVstsFeed: $(ROSWinPublicFeedId)
allowPackageConflicts: true