Skip to content

Commit cb53782

Browse files
Refactor matrix into steps
1 parent abb0aec commit cb53782

File tree

1 file changed

+47
-20
lines changed

1 file changed

+47
-20
lines changed

.buildkite/pipeline.yml

Lines changed: 47 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -23,30 +23,29 @@ steps:
2323
#################
2424
- group: "📦 Build and Test Swift Package"
2525
steps:
26-
- label: "📦 Build and Test Swift Package (Swift {{matrix.swift_version}})"
26+
- label: "📦 Build and Test Swift Package ($CURRENT_SWIFT_VERSION)"
27+
command: |
28+
validate_swift_package test device_model:"$CURRENT_DEVICE" os:"$CURRENT_OS"
2729
key: "test"
30+
env:
31+
IMAGE_ID: "$CURRENT_IMAGE_ID"
32+
plugins: [$CI_TOOLKIT]
33+
34+
- label: "📦 Build and Test Swift Package ($SWIFT_5_9_VERSION)"
2835
command: |
29-
validate_swift_package test device_model:"{{matrix.device_model}}" os:"{{matrix.device_os}}"
36+
validate_swift_package test device_model:"$SWIFT_5_9_DEVICE" os:"$SWIFT_5_9_OS"
37+
key: "test_swift_5_9"
38+
env:
39+
IMAGE_ID: "$SWIFT_5_9_IMAGE_ID"
3040
plugins: [$CI_TOOLKIT]
41+
42+
- label: "📦 Build and Test Swift Package ($SWIFT_6_0_VERSION)"
43+
command: |
44+
validate_swift_package test device_model:"$SWIFT_6_0_DEVICE" os:"$SWIFT_6_0_OS"
45+
key: "test_swift_5_9"
3146
env:
32-
IMAGE_ID: "{{matrix.image_id}}"
33-
matrix:
34-
setup: # Specify the current version of Xcode, Swift, a device, and the required version of iOS
35-
image_id: $CURRENT_IMAGE_ID
36-
swift_version: $CURRENT_SWIFT_VERSION
37-
device_model: $CURRENT_DEVICE
38-
device_os: $CURRENT_OS
39-
adjustments: # Specify additional versions of Xcode, Swift, a device, and the required version of iOS
40-
- with: # Swift 5.9
41-
image_id: $SWIFT_5_9_IMAGE_ID
42-
swift_version: $SWIFT_5_9_VERSION
43-
device_model: $SWIFT_5_9_DEVICE
44-
device_os: $SWIFT_5_9_OS
45-
- with: # Swift 6.0
46-
image_id: $SWIFT_6_0_IMAGE_ID
47-
swift_version: $SWIFT_6_0_VERSION
48-
device_model: $SWIFT_6_0_DEVICE
49-
device_os: $SWIFT_6_0_OS
47+
IMAGE_ID: "$SWIFT_6_0_IMAGE_ID"
48+
plugins: [$CI_TOOLKIT]
5049

5150
###################
5251
# Validate Podspec
@@ -125,3 +124,31 @@ steps:
125124
plugins: [$CI_TOOLKIT]
126125
command: .buildkite/commands/upload-to-appcenter.sh UIKit
127126
if: build.pull_request.id != null
127+
128+
- group: "🔬 Validate Podspecs"
129+
steps:
130+
- label: "🛠️ Build SwiftUI Demo ({{matrix.swift_version}})"
131+
depends_on: build_swiftui
132+
plugins: [$CI_TOOLKIT]
133+
command: |
134+
install_gems
135+
BUILD_NUMBER=$BUILDKITE_BUILD_NUMBER make build-demo-for-distribution-swiftui
136+
env:
137+
IMAGE_ID: "{{matrix.image_id}}"
138+
matrix:
139+
setup: # Specify the current version of Xcode, Swift, a device, and the required version of iOS
140+
image_id: $CURRENT_IMAGE_ID
141+
swift_version: $CURRENT_SWIFT_VERSION
142+
device_model: $CURRENT_DEVICE
143+
device_os: $CURRENT_OS
144+
adjustments: # Specify additional versions of Xcode, Swift, a device, and the required version of iOS
145+
- with: # Swift 5.9
146+
image_id: $SWIFT_5_9_IMAGE_ID
147+
swift_version: $SWIFT_5_9_VERSION
148+
device_model: $SWIFT_5_9_DEVICE
149+
device_os: $SWIFT_5_9_OS
150+
- with: # Swift 6.0
151+
image_id: $SWIFT_6_0_IMAGE_ID
152+
swift_version: $SWIFT_6_0_VERSION
153+
device_model: $SWIFT_6_0_DEVICE
154+
device_os: $SWIFT_6_0_OS

0 commit comments

Comments
 (0)