mirai/mirai-demos/mirai-demo-android/build.gradle
2020-02-02 23:20:34 +08:00

64 lines
2.2 KiB
Groovy

plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.multiplatform'
id 'kotlin-android-extensions'
}
android {
compileSdkVersion 29
defaultConfig {
applicationId "net.mamoe.mirai.demo"
minSdkVersion 21
targetSdkVersion 29
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions {
exclude 'META-INF/main.kotlin_module'
exclude 'META-INF/ktor-http.kotlin_module'
exclude 'META-INF/kotlinx-io.kotlin_module'
exclude 'META-INF/atomicfu.kotlin_module'
exclude 'META-INF/ktor-utils.kotlin_module'
exclude 'META-INF/kotlinx-coroutines-io.kotlin_module'
exclude 'META-INF/kotlinx-coroutines-core.kotlin_module'
exclude 'META-INF/ktor-http-cio.kotlin_module'
exclude 'META-INF/ktor-http-cio.kotlin_module'
exclude 'META-INF/ktor-client-core.kotlin_module'
exclude "META-INF/kotlinx-serialization-runtime.kotlin_module"
}
}
kotlin {
targets.fromPreset(presets.android, 'android')
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib"
implementation project(':mirai-core-qqandroid')
implementation group: 'org.jetbrains.kotlin', name: 'kotlin-stdlib-jdk8', version: kotlinVersion
implementation group: 'org.jetbrains.kotlinx', name: 'kotlinx-coroutines-core', version: coroutinesVersion
implementation group: 'org.jetbrains.kotlinx', name: 'kotlinx-coroutines-android', version: "1.3.2"
//implementation 'com.android.support:appcompat-v7:29.1.1'// https://mvnrepository.com/artifact/androidx.appcompat/appcompat
implementation group: 'androidx.appcompat', name: 'appcompat', version: '1.1.0'
testImplementation "org.jetbrains.kotlin:kotlin-test"
testImplementation 'junit:junit:4.12'
androidTestImplementation 'junit:junit:4.12'
def anko_version = "0.10.8"
implementation "org.jetbrains.anko:anko-commons:$anko_version"
implementation group: 'io.ktor', name: 'ktor-client-android', version: '1.2.5'
implementation("io.ktor:ktor-client-android:1.2.5")
}