Skip to content

Latest commit

 

History

History
70 lines (54 loc) · 2.42 KB

INSTALLATION.md

File metadata and controls

70 lines (54 loc) · 2.42 KB

Installation

Gradle

Add the dependency from Maven Central to your app module's (not top-level) build.gradle file:

repositories {
    mavenCentral()
}

dependencies {
    implementation 'dev.hotwire:turbo:<latest-version>'
}

Download

See the latest version available on Maven Central.

Note: As of May 1, 2021, artifacts will no longer be released to JCenter, since it's shutting down.

Required minSdkVersion

Android SDK 24 (or greater) is required as the minSdkVersion in your app module's build.gradle file:

defaultConfig {
    minSdkVersion 24
    // ...
}

Internet Permission

In order for a WebView to access the Internet and load web pages, your app must have the INTERNET permission. Make sure you include this permission in your app's AndroidManifest.xml file:

<uses-permission android:name="android.permission.INTERNET"/>

Pre-release Builds

Pre-release builds will be published to GitHub Packages.

Personal Access Token

If you'd like to use a pre-release version, you'll need to create a Personal Access Token in your GitHub account and give it the read:packages permission.

Copy your access token to your .bash_profile (or another accessible place that's outside of source control):

export GITHUB_USER='<your username>'
export GITHUB_ACCESS_TOKEN='<your personal access token>'

Gradle

Add the GitHub Packages maven repository and the dependency to your app module's build.gradle file:

repositories {
    maven {
        name = "GitHubPackages"
        url = uri("https://maven.pkg.github.com/hotwired/turbo-android")

        credentials {
            username = System.getenv('GITHUB_USER')
            password = System.getenv('GITHUB_ACCESS_TOKEN')
        }
    }
}

dependencies {
    implementation 'dev.hotwire:turbo:<latest-version>'
}

See the latest version available on GitHub Packages.