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.
Permalink
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
.github/ISSUE_TEMPLATE
cloudformation
config
gradle
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
README.md Update README to include Snapshot repository Nov 13, 2019
build.gradle
codecov.yml
gradle.properties
gradlew First Commit: Nov 8, 2019
gradlew.bat First Commit: Nov 8, 2019
package-lock.json
package.json
settings.gradle

README.md

CircleCI

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 https://semver.org/ . 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 https://github.com/google/play-services-plugins/tree/master/oss-licenses-plugin

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: 'com.mapbox.android.sdk.versions'

or

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

subprojects { subProject ->
 afterEvaluate {
     subProject.apply plugin: 'com.mapbox.android.sdk.versions'
 }
}

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 {
        mavenCentral()
        maven { url "http://oss.sonatype.org/content/repositories/snapshots/" }
    }

  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.