-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Releasing the Mapbox macOS SDK
Congratulations, you’re the proud owner of a new release of the Mapbox Maps SDK for macOS! The process below takes half an hour to an hour, most of it babysitting the compiler.
To the extent possible, we release the Mapbox Maps SDK for macOS in tandem with the Mapbox Maps SDK for iOS, so that developers who work on both platforms can count on feature parity and the same bug fixes between the two SDKs. However, if a critical bug fix affects only macOS, we may issue an out-of-band release of the macOS SDK; conversely, we may delay the macOS SDK release if a critical issue arises in the iOS SDK.
Takes under 5 minutes
- Skim the issues tagged macOS or issues mentioning “macOS” in case there are any showstoppers.
- Run
tx pull -a
to add or update translations. - Update the first section of the changelog to reflect any notable changes to the SDK, shared iOS/macOS code, or mbgl since the previous release. Compare the previous release tag with master or the release branch to find notable changes. Look in particular for commit messages prefixed with
[macos]
,[ios, macos]
, or[core]
. - If the screenshot hasn’t been updated in awhile, compose a new version that shows off the new release’s features. Try to show styles, cities, or features that haven’t been depicted in the macOS SDK screenshot before.
- Commit these changes and open a PR to get them reviewed and merged.
Takes under 5 minutes
- Decide on a semver-compliant version number according to these guidelines. The version number should be of the form 0.9.8-alpha.1, 0.9.8-beta.1, 0.9.8-rc.1 (for a release candidate), or 0.9.8 (for a final release).
- Run
./platform/macos/scripts/update-version.sh v0.9.8
, where 0.9.8 is the semver-compliant version you chose in step 1. Commit the resulting changes with a commit message likemacos-v0.9.8
and open a PR to get it reviewed and merged. - Tag the merged podspec changes as
macos-v0.9.8
, where 0.9.8 is the semver-compliant version you chose in step 1. Push the tag.
Takes 15–30 minutes
- Run
xcodebuild -version
orxcode-select -p
to make sure you’re building with the right version of Xcode. - If this is your first time releasing the Mapbox Maps SDK for macOS:
- Install
wget
andgithub-release
from Homebrew andcaffeinate
from RubyGems. - Add
export GITHUB_TOKEN='8BADF00DDEADBEEFC00010FF'
to your .bash_profile, where 8BADF00DDEADBEEFC00010FF is a new GitHub personal access token. - Optionally, to code-sign Mapbox GL.app, you’ll need to install a provisioning profile for your Mac Developer Program membership.
- Install
- Make sure your Mac is plugged in, then run
make xdeploy
. A script will build the SDK, package it up, and finally upload the package to a new GitHub release, all the while keeping your computer from falling asleep. - While you wait, draft a new release. Add release notes based on the release’s section in the changelog. (Unlike the changelog, release notes accept
#123
syntax for linking to PRs.) Use one of these templates: - Once the script runs to completion, it should have drafted a new GitHub release with binary packages attached. Copy the release notes you drafted above into the new release. Title the release
macos-v0.9.8
(where 0.9.8 is the new version). Save the draft. - Check “This is a pre-release” if applicable, then click “Publish release”. Delete the other draft you made.
Takes 5–10 minutes
- Update the Mapbox Maps SDK for macOS documentation site (which is also bundled with the SDK):
- Clone mapbox-gl-native to a mapbox-gl-native-pages folder alongside your main mapbox-gl-native clone, and check out the
gh-pages
branch. - In your main mapbox-gl-native clone, check out the release branch and run
make xdocument STANDALONE=1 OUTPUT=../mapbox-gl-native-pages/macos/0.9.8
, where 0.9.8 is the new SDK version. - In mapbox-gl-native-pages, edit macos/index.html and macos/docsets/Mapbox.xml to refer to the new SDK version.
- In mapbox-gl-native-pages, edit macos/Mapbox-macOS-SDK.json and macos/Mapbox-macOS-SDK-symbols.json.
- Commit and push your changes to the
gh-pages
branch.
- Clone mapbox-gl-native to a mapbox-gl-native-pages folder alongside your main mapbox-gl-native clone, and check out the
- If any new style properties or features are supported in the new release, update the “SDK support” tables in the style specification documentation:
- If this is your first time updating the style specification documentation, install
yarn
from Homebrew. - Update the
sdk-support
objects in v8.json. Themacos
key in ansdk-support
object for a particular property indicates the minimum macOS SDK version that supports that property. If thesdk-support
object is missing amacos
key, the property is assumed to be unsupported in the macOS SDK. - If the release adds support for features other than properties, update docs/style-spec/_generate/index.html.
- Run
yarn install && yarn run build-style-spec
to generate the style specification site. - Commit these changes and open a PR in the mapbox-gl-js repository to get them reviewed and merged. (Keep going while you wait for a review.)
- Once the PR is merged, cherry-pick the changes into the mb-pages branch, so that they go live on mapbox.com ahead of the next Mapbox GL JS release.
- If this is your first time updating the style specification documentation, install
- Edit this table at the OpenStreetMap Wiki to correctly indicate the status of any new features.
Takes under 5 minutes
- If this is your first time releasing the Mapbox Maps SDK for macOS:
- Sign up for a CocoaPods trunk account.
- Get one of the Mapbox-macOS-SDK pod’s owners to add you as an owner.
- Once the documentation site finishes publishing the updates, push the podspecs to CocoaPods trunk:
pod trunk push platform/macos/Mapbox-macOS-SDK.podspec pod trunk push platform/macos/Mapbox-macOS-SDK-symbols.podspec
- Copy
pod
’s success message and let Mapbox’s Mobile team know about the new release by sending this message to the#mobile
Slack channel if you work for Mapbox or the#gl-collab
Slack channel if you don’t. - Submit an update to OSMBC to get a mention in the next issue of WeeklyOSM.
Whew! Now you can close the release’s milestone and create one for the next release!
Workflow: Code, Makefile, CMake, Xcode, ccache, Debugging, CI, JS/Native, Code Generation, Versions & Tagging, Contributing, Troubleshooting
Architecture: Threads, Immutability, Expressions, Text Rendering, Collision Detection, CJK Text
Rendering: OpenGL, Coordinate Systems
Android: checkstyle, APK Size, 4→5, 5→6, 6→7, Symbolication
iOS/macOS: 3→4
Releasing: iOS, macOS, Merging back
Misc: Terminology