forked from xamarin/Xamarin.Forms
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathazure-pipelines.yml
150 lines (140 loc) · 3.96 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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
variables:
- name: DefaultBuildConfiguration
value: Debug
- name: DefaultBuildPlatform
value: 'any cpu'
- name: ApkName
value: AndroidControlGallery.AndroidControlGallery.apk
- name: IpaName
value: XamarinFormsControlGalleryiOS.ipa
- name: SolutionFile
value: Xamarin.Forms.sln
- name: BuildVersion
value: $[counter('nuget-counter', 126)]
- name: BuildVersion42
value: $[counter('xf-nuget-counter', 992000)]
- name: BuildVersion43
value: $[counter('xf-nuget-counter', 992000)]
- name: BuildVersion44
value: $[counter('xf-nuget-counter', 992000)]
- name: NUGET_VERSION
value: 5.4.0
- name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE
value: true
- name: DOTNET_VERSION
value: 3.1.100
resources:
repositories:
- repository: xamarin-templates
type: github
name: xamarin/yaml-templates
endpoint: xamarin
trigger:
branches:
include:
- master
- 3.*
- 4.*
tags:
include:
- '*'
paths:
exclude:
- README.md
pr:
autoCancel: false
branches:
include:
- master
- 4.*
- 3.*
schedules:
- cron: "0 0 * * *"
displayName: Daily midnight build
branches:
include:
- master
stages:
- stage: windows
displayName: Build Windows
jobs:
- template: build/steps/build-windows.yml
parameters:
name: win
displayName: Build Windows Phase
vmImage: $(vs2019VmImage)
vmPool: $(vs2019VmPool)
provisionatorPath : 'build/provisioning/provisioning.csx'
- job: nuget_pack
workspace:
clean: all
dependsOn:
- win
displayName: Nuget Phase
condition: succeeded()
pool:
name: $(vs2019VmPool)
vmImage: $(vs2019VmImage)
variables:
FormsIdAppend: ''
buildConfiguration: $(DefaultBuildConfiguration)
nugetPackageVersion : $[ dependencies.win.outputs['debug.winbuild.xamarinformspackageversion'] ]
steps:
- template: build/steps/build-nuget.yml
- stage: android
displayName: Build Android
${{ if eq(variables['System.TeamProject'], 'devdiv') }}:
dependsOn: windows
${{ if eq(variables['System.TeamProject'], 'public') }}:
dependsOn: []
jobs:
- template: build/steps/build-android.yml
parameters:
vmImage: $(macOSXVmImage)
provisionatorPath : 'build/provisioning/provisioning.csx'
- stage: build_osx
displayName: Build OSX
${{ if eq(variables['System.TeamProject'], 'devdiv') }}:
dependsOn: windows
${{ if eq(variables['System.TeamProject'], 'public') }}:
dependsOn: []
jobs:
- job: osx
workspace:
clean: all
displayName: OSX Phase
strategy:
matrix:
BuildForVS2017:
buildForVS2017: 'true'
imageName : 'macOS-10.14'
BuildForVS2019:
buildForVS2017: 'false'
imageName : 'macOS-10.14'
pool:
vmImage: $(imageName)
demands:
- sh
- msbuild
- Xamarin.iOS
variables:
provisionator.osxPath : 'build/provisioning/provisioning.csx'
buildConfiguration: $(DefaultBuildConfiguration)
iOSCertSecureFileName: 'Xamarin Forms iOS Certificate.p12'
iOSProvisioningSecureFileName: 'Xamarin Forms iOS Provisioning.mobileprovision'
buildForVS2017: $(buildForVS2017)
steps:
- template: build/steps/build-osx.yml
# only sign using the private server
- ${{ if eq(variables['System.TeamProject'], 'devdiv') }}:
- stage: nuget_signing
dependsOn: windows
displayName: Sign Nuget
jobs:
- job: nuget_sign
displayName: Sign Phase
pool:
name: $(signVmImage)
steps:
- template: build/steps/build-sign.yml
condition: and(succeeded(), or(eq(variables['Sign'], 'true'), or(eq(variables['Build.SourceBranch'], 'refs/heads/master'), startsWith(variables['Build.SourceBranch'],'refs/tags/'))))