Skip to content

Commit

Permalink
ci: Use script file to simplify current working directory management
Browse files Browse the repository at this point in the history
Various Buildkite commands failed when using Makefile commands as the
current working directory is not persisted with each new line.
  • Loading branch information
dcalhoun committed Dec 2, 2024
1 parent 6113484 commit ac7b26a
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 8 deletions.
4 changes: 3 additions & 1 deletion .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,7 @@ steps:
plugins: *plugins

- label: ':ios: Publish iOS Artifacts'
command: make publish-ios-artifacts
command: |
make build
.buildkite/scripts/publish-ios-artifacts.sh
plugins: *plugins
11 changes: 11 additions & 0 deletions .buildkite/scripts/publish-ios-artifacts.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/bash -eu

echo "--- :rubygems: Installing Ruby Dependencies"
pushd ./ios > /dev/null
install_gems

echo "--- :s3: Uploading iOS artifacts to S3"
bundle exec fastlane upload_ios_artifacts_to_s3

# Restore the working directory
popd > /dev/null
7 changes: 0 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,3 @@ build-swift-package: build

test-swift-package: build
$(call XCODEBUILD_CMD, test)

publish-ios-artifacts: build
echo "--- :rubygems: Installing Ruby Dependencies"
cd ./ios && \
install_gems && \
echo "--- :s3: Uploading iOS artifacts to S3" && \
bundle exec fastlane upload_ios_artifacts_to_s3

0 comments on commit ac7b26a

Please sign in to comment.