Skip to content
This plugin validates and persists Mapbox SDK versions in a file(in assets folder) at compile time.
Groovy JavaScript Makefile Java
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
.circleci Add missing publish step for tag in config.yml Nov 13, 2019
src Add Empty Java class Nov 14, 2019
.gitignore First Commit: Nov 8, 2019
CHANGELOG.MD Bump version and update CHANGELOG.MD Nov 14, 2019
Makefile First Commit: Nov 8, 2019 Update README to include Snapshot repository Nov 13, 2019
gradlew First Commit: Nov 8, 2019
gradlew.bat First Commit: Nov 8, 2019


Persist Mapbox SDK Versions

About android-sdk-versions-plugin

This plugin persists Mapbox android SDK version information(for every library module) in a file at compile time for further access at run time. This plugin also validates the version to be compliant with . The persisted file is named after applicationId(for e.g. com.mapbox.andorid.core) and the file content is in the following format.

SDK Module Name/Version
Version Code

This plugin is inspired from

All android SDK library modules at Mapbox should apply this plugin to facilitate the Telemetry SDK access all Mapbox SDK versions at run time.

Add the Gradle plugin

In your root-level build.gradle, make sure you are using the Maven Central Repository and add android-sdk-versions-plugin to your dependencies

  dependencies {
    // ...
        // Add this line:
        classpath 'com.mapbox.mapboxsdk:mapbox-android-sdk-versions:X.X.X'

Apply the Gradle plugin

In all your module (library) level build.gradle files, apply the plugin.

apply plugin: ''


If all modules in your project are libraries, add this in project's root build.gradle file.

subprojects { subProject ->
 afterEvaluate {
     subProject.apply plugin: ''

Using Snapshots

If you want to test recent bug fixes or features that have not been packaged in an official release yet, you can use a -SNAPSHOT release of the current development version, available on Sonatype.

    repositories {
        maven { url "" }

  dependencies {
    // ...
        // Add this line:
        classpath 'com.mapbox.mapboxsdk:mapbox-android-sdk-versions:X.X.X-SNAPSHOT'

You can’t perform that action at this time.