Skip to content

Instantly share code, notes, and snippets.

@willyliu
Created September 8, 2017 10:32
Show Gist options
  • Save willyliu/a720e844aecee8f6f9ff9947a1051cc8 to your computer and use it in GitHub Desktop.
Save willyliu/a720e844aecee8f6f9ff9947a1051cc8 to your computer and use it in GitHub Desktop.
How to modify module's gradle file to include kotlin file manually for android.
// for compiling kotlin files
apply plugin: 'kotlin-android'
buildscript {
repositories {
jcenter()
}
ext.kotlin_version = '1.1.4-3'
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
// the dependency setting for kotlin runtime
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment