-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathazure-pipelines-ios.yml
153 lines (134 loc) · 4.91 KB
/
azure-pipelines-ios.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
149
150
151
152
153
# Node.js
# Build a general Node.js project with npm.
# Add steps that analyze code, save build artifacts, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript
trigger:
- master
pool:
vmImage: macOS-latest
variables:
scheme: "Artsorakel"
sdk: "iphoneos"
configuration: "Release"
system.debug: true
steps:
- task: InstallAppleCertificate@2
inputs:
certSecureFile: "artsorakel.p12"
certPwd: $(appCertificatePassword)
keychain: "temp"
deleteCert: true
- task: InstallAppleProvisioningProfile@1
inputs:
provProfileSecureFile: "ArtsorakelNewProvisionProfile.mobileprovision"
removeProfile: true
# - task: DownloadSecureFile@1
# inputs:
# secureFile: 'fonts.zip'
# - task: DownloadSecureFile@1
# inputs:
# secureFile: 'build.json'
# - task: DownloadSecureFile@1
# inputs:
# secureFile: 'orakel_keystore.jks'
# - task: ExtractFiles@1
# inputs:
# archiveFilePatterns: '/Users/runner/work/_temp/fonts.zip'
# destinationFolder: 'src'
# cleanDestinationFolder: false
# overwriteExistingFiles: true
# - task: NodeTool@0
# inputs:
# versionSpec: 'latest'
# displayName: 'Install Node.js'
# - script: |
# npm install
# npm install -g cordova
# npm run build
# cp -R build/ www/
# cordova platform add android
# cp /Users/runner/work/_temp/build.json .
# cp /Users/runner/work/_temp/orakel_keystore.jks .
# cp /Users/runner/Library/Android/sdk/build-tools/32.0.0/d8 /Users/runner/Library/Android/sdk/build-tools/32.0.0/dx
# cp /Users/runner/Library/Android/sdk/build-tools/32.0.0/lib/d8.jar /Users/runner/Library/Android/sdk/build-tools/32.0.0/lib/dx.jar
# cp /Users/runner/Library/Android/sdk/build-tools/33.0.1/d8 /Users/runner/Library/Android/sdk/build-tools/33.0.1/dx
# cp /Users/runner/Library/Android/sdk/build-tools/33.0.1/lib/d8.jar /Users/runner/Library/Android/sdk/build-tools/33.0.1/lib/dx.jar
# cordova build android --release --buildConfig=build.json -- --packageType=bundle
# displayName: 'build Android'
# - task: CopyFiles@2
# inputs:
# contents: 'platforms/android/**/*.aab'
# targetFolder: '$(build.artifactStagingDirectory)'
# displayName: Copy .apk files to artifact staging directory
# - task: PublishBuildArtifacts@1
# inputs:
# pathToPublish: '$(build.artifactStagingDirectory)'
# artifactName: 'drop'
# artifactType: 'container'
# displayName: Publish Android artifacts
- task: NodeTool@0
inputs:
versionSpec: "18.14"
displayName: "Install Node.js"
# Cache v2
# Cache files between runs.
# - task: Cache@2
# inputs:
# key: nodemodules # string. Required. Key.
# path: node_modules # string. Required. Path.
# Cache files between runs.
# - task: Cache@2
# inputs:
# key: pods # string. Required. Key.
# path: ios/Pods # string. Required. Path.
- script: |
npm install
npm update
- task: CocoaPods@0
displayName: "Install CocoaPods"
inputs:
workingDirectory: "ios"
- task: Xcode@5
displayName: "Build IPA"
inputs:
actions: "build"
configuration: "Release"
sdk: "iphoneos"
xcWorkspacePath: "ios/Artsorakel.xcworkspace"
scheme: "Artsorakel"
packageApp: true
exportPath: "output"
signingOption: "manual"
signingIdentity: "$(APPLE_CERTIFICATE_SIGNING_IDENTITY)"
provisioningProfileUuid: "$(APPLE_PROV_PROFILE_UUID)"
# - script: |
# npm install
# react-native bundle --platform ios --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res/
# react-native bundle --platform ios --dev false --entry-file index.js --bundle-output ios/main.jsbundle
# # cordova platform remove ios
# # cordova platform add ios@latest
# # cordova build ios --buildFlag="-UseModernBuildSystem=0" --codeSignIdentity="iPhone Developer" --developementTeam="Artsdatabanken" --packageType="app-store"
# displayName: 'build Mac'
# - task: Xcode@5
# inputs:
# actions: 'build'
# scheme: '$(scheme)'
# sdk: '$(sdk)'
# configuration: '$(configuration)'
# xcWorkspacePath: 'platforms/ios/Artsorakel.xcworkspace'
# xcodeVersion: '12'
# signingOption: 'manual'
# signingIdentity: '$(APPLE_CERTIFICATE_SIGNING_IDENTITY)'
# provisioningProfileUuid: '$(APPLE_PROV_PROFILE_UUID)'
# packageApp: true
- task: CopyFiles@2
inputs:
contents: "**/*.ipa"
targetFolder: "$(build.artifactStagingDirectory)"
displayName: Copy .ipa files to artifact staging directory
- task: PublishBuildArtifacts@1
inputs:
pathtoPublish: "$(build.artifactStagingDirectory)"
artifactName: "drop"
publishLocation: "Container"
displayName: Publish Iphone artifacts