Skip to content

Commit d2f8e3a

Browse files
evil159github-actions[bot]
authored andcommitted
[maps-ios] Setup binary distribution with SPM (#10105)
Set up publishing for prebuilt MapboxMaps.xcframework binaries with SPM in https://github.com/mapbox/mapbox-maps-ios-binary. ### What changed * CI(`CD.yml`) builds the xcframework, computes checksum, and publishes package contents to individual branches in `mapbox-maps-ios-binary`, creates gh release when necessary. * Up to date license is being published along with snapshot/release of common/gl native/maps iOS SDKs. Also consolidated the separate maps copybara workflows into one file since they were doing the same thing. - [x] TODO: Make `mapbox-maps-ios-binary` public before merging Test run: https://github.com/mapbox/mapbox-sdk/actions/runs/22222946360 Addresses https://mapbox.atlassian.net/browse/MAPSIOS-2058 `api-downloads` PR: mapbox/api-downloads#4991 cc @mapbox/sdk-platform cc @mapbox/maps-ios cc @mapbox/maps-android cc @mapbox/maps-flutter GitOrigin-RevId: f7e74964ec69220d1510e5e24ad230f4ec9c8097
1 parent d1e7673 commit d2f8e3a

2 files changed

Lines changed: 17 additions & 4 deletions

File tree

scripts/release/create-github-draft-release.sh

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ XCODE_MIN_VERSION=$2
1212
GITHUB_TOKEN=$3
1313
GITHUB_WRITER_TOKEN=$4
1414

15-
set -euo pipefail
1615
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
1716
UTILS_PATH="$SCRIPT_DIR/../utils.sh"
1817

@@ -42,14 +41,28 @@ $CHANGELOG
4241
* Compatible version of Xcode: \`$XCODE_MIN_VERSION\`
4342
EOF
4443

45-
PRODUCTION_DOCS_PR_URL=$(GITHUB_TOKEN=$GITHUB_WRITER_TOKEN \
44+
MAIN_RELEASE_URL=$(GITHUB_TOKEN=$GITHUB_WRITER_TOKEN \
4645
gh release create "v$VERSION" --repo mapbox/mapbox-maps-ios \
4746
--prerelease \
4847
--draft \
4948
--title "v$VERSION" \
5049
--notes-file notes.txt)
5150

52-
info "New Release: $PRODUCTION_DOCS_PR_URL"
51+
info "New Release: $MAIN_RELEASE_URL"
52+
53+
if [[ "$VERSION" =~ ^[0-9]+\.[0-9]+\.[0-9]+- ]]; then
54+
PRERELEASE_FLAG="--prerelease"
55+
else
56+
PRERELEASE_FLAG=""
57+
fi
58+
59+
BINARY_RELEASE_URL=$(GITHUB_TOKEN=$GITHUB_WRITER_TOKEN \
60+
gh release create "v$VERSION" --repo mapbox/mapbox-maps-ios-binary \
61+
$PRERELEASE_FLAG \
62+
--title "v$VERSION" \
63+
--notes "📖 For release notes and changelog, see: [mapbox-maps-ios v$VERSION](https://github.com/mapbox/mapbox-maps-ios/releases/tag/v$VERSION)")
64+
65+
info "Binary Release: $BINARY_RELEASE_URL"
5366
}
5467

5568
main

scripts/release/upload-to-registry.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,6 @@ step "Uploading ${SOURCE_ZIP} to ${S3_DESTINATION}"
2828
aws s3 cp ${SOURCE_ZIP} ${S3_DESTINATION} ${S3_ARGS:-}
2929
step "Download URL will be ${DOWNLOAD_URL}"
3030

31-
if [[ -n "${GITHUB_STEP_SUMMARY:-}" ]]; then
31+
if [[ -n "${GITHUB_STEP_SUMMARY:-}" && "${PROJECT}" == "mobile-maps-ios" ]]; then
3232
echo "${ZIP_FILENAME}: \`${DOWNLOAD_URL}\`" >> $GITHUB_STEP_SUMMARY
3333
fi

0 commit comments

Comments
 (0)