Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .buildkite/commands/build-for-testing.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,19 @@ echo "--- Installing Secrets"
bundle exec fastlane run configure_apply

echo "--- :hammer_and_wrench: Building"
set +e
bundle exec fastlane build_for_testing
BUILD_EXIT_STATUS=$?
set -e

if [[ $BUILD_EXIT_STATUS -ne 0 ]]; then
# Keep the (otherwise collapsed) current section open in Buildkite logs on error. See https://buildkite.com/docs/pipelines/managing-log-output#collapsing-output
echo "^^^ +++"
echo "Build failed!"
fi

echo "--- :arrow_up: Upload Build Products"
tar -cf build-products.tar DerivedData/Build/Products/
upload_artifact build-products.tar

exit $BUILD_EXIT_STATUS
9 changes: 9 additions & 0 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,15 @@ steps:
command: ".buildkite/commands/build-for-testing.sh"
env: *common_env
plugins: *common_plugins
artifact_paths:
- "build/results/*" # FIXME: Note that there's nothing in there–because we only build, not run the tests?
# FIXME: Why isn't there any file in there?! See https://buildkite.com/automattic/wordpress-ios/builds/7828#964dc9dc-b8ec-4562-8d78-64fccffc0fd2
# - "DerivedData/Logs/Build/*.xcactivitylog"
#
# Note to self: You can't upload _folder_ on Buildkite, only files.
# _If_ you anted to upload the whole DerivedData folder, you'd have to zip it first.
# - DerivedData
- DerivedData/WordPress/Logs/Build/*.xcactivitylog
notify:
- github_commit_status:
context: "Build for Testing"
Expand Down