mirror of
https://github.com/czp3009/bilibili-api.git
synced 2024-12-21 20:30:28 +08:00
95 lines
3.3 KiB
Groovy
95 lines
3.3 KiB
Groovy
buildscript {
|
|
ext {
|
|
kotlin_version = '1.3.21'
|
|
kotlin_coroutines_version = '1.1.1'
|
|
ktor_version = '1.1.3'
|
|
jvm_target = JavaVersion.VERSION_1_8
|
|
}
|
|
|
|
repositories {
|
|
gradlePluginPortal()
|
|
}
|
|
|
|
dependencies {
|
|
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
|
}
|
|
}
|
|
|
|
group = 'com.hiczp'
|
|
version = '0.1.0'
|
|
description = 'Bilibili Android client API library for Kotlin'
|
|
|
|
apply plugin: 'kotlin'
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
mavenLocal()
|
|
}
|
|
|
|
//kotlin
|
|
dependencies {
|
|
// https://mvnrepository.com/artifact/org.jetbrains.kotlin/kotlin-stdlib-jdk8
|
|
compile group: 'org.jetbrains.kotlin', name: 'kotlin-stdlib-jdk8'
|
|
// https://mvnrepository.com/artifact/org.jetbrains.kotlinx/kotlinx-coroutines-core
|
|
compile group: 'org.jetbrains.kotlinx', name: 'kotlinx-coroutines-core', version: kotlin_coroutines_version
|
|
// https://mvnrepository.com/artifact/org.jetbrains.kotlinx/kotlinx-coroutines-jdk8
|
|
compile group: 'org.jetbrains.kotlinx', name: 'kotlinx-coroutines-jdk8', version: kotlin_coroutines_version
|
|
}
|
|
compileKotlin {
|
|
kotlinOptions {
|
|
jvmTarget = jvm_target
|
|
freeCompilerArgs = ["-Xjvm-default=enable", "-Xuse-experimental=kotlin.Experimental"]
|
|
}
|
|
}
|
|
compileTestKotlin {
|
|
kotlinOptions.jvmTarget = jvm_target
|
|
}
|
|
|
|
//logging
|
|
dependencies {
|
|
// https://mvnrepository.com/artifact/io.github.microutils/kotlin-logging
|
|
compile group: 'io.github.microutils', name: 'kotlin-logging', version: '1.6.25'
|
|
// https://mvnrepository.com/artifact/org.slf4j/slf4j-simple
|
|
testCompile group: 'org.slf4j', name: 'slf4j-simple', version: '1.7.26'
|
|
}
|
|
|
|
//http
|
|
dependencies {
|
|
// https://mvnrepository.com/artifact/com.squareup.retrofit2/retrofit
|
|
compile group: 'com.squareup.retrofit2', name: 'retrofit', version: '2.5.0'
|
|
// https://mvnrepository.com/artifact/com.squareup.retrofit2/converter-gson
|
|
compile group: 'com.squareup.retrofit2', name: 'converter-gson', version: '2.5.0'
|
|
// https://mvnrepository.com/artifact/com.github.salomonbrys.kotson/kotson
|
|
compile group: 'com.github.salomonbrys.kotson', name: 'kotson', version: '2.5.0'
|
|
// https://mvnrepository.com/artifact/com.jakewharton.retrofit/retrofit2-kotlin-coroutines-adapter
|
|
compile group: 'com.jakewharton.retrofit', name: 'retrofit2-kotlin-coroutines-adapter', version: '0.9.2'
|
|
// https://mvnrepository.com/artifact/com.squareup.okhttp3/logging-interceptor
|
|
compile group: 'com.squareup.okhttp3', name: 'logging-interceptor', version: '3.13.1'
|
|
}
|
|
|
|
//ktor
|
|
dependencies {
|
|
// https://mvnrepository.com/artifact/io.ktor/ktor-client-websocket
|
|
compile group: 'io.ktor', name: 'ktor-client-websocket', version: ktor_version
|
|
// https://mvnrepository.com/artifact/io.ktor/ktor-client-cio
|
|
compile group: 'io.ktor', name: 'ktor-client-cio', version: ktor_version
|
|
}
|
|
|
|
//utils
|
|
dependencies {
|
|
// https://mvnrepository.com/artifact/commons-io/commons-io
|
|
compile group: 'commons-io', name: 'commons-io', version: '2.6'
|
|
}
|
|
|
|
//checksum
|
|
dependencies {
|
|
// https://mvnrepository.com/artifact/com.hiczp/crc32-crack
|
|
compile group: 'com.hiczp', name: 'crc32-crack', version: '1.0'
|
|
}
|
|
|
|
//unit test
|
|
dependencies {
|
|
// https://mvnrepository.com/artifact/org.junit.jupiter/junit-jupiter
|
|
testCompile group: 'org.junit.jupiter', name: 'junit-jupiter', version: '5.4.0'
|
|
}
|