2020-11-01 15:07:32 +08:00
|
|
|
/*
|
2021-01-01 17:26:55 +08:00
|
|
|
* Copyright 2019-2021 Mamoe Technologies and contributors.
|
2020-11-01 15:07:32 +08:00
|
|
|
*
|
|
|
|
* 此源代码的使用受 GNU AFFERO GENERAL PUBLIC LICENSE version 3 许可证的约束, 可以在以下链接找到该许可证.
|
|
|
|
* Use of this source code is governed by the GNU AGPLv3 license that can be found through the following link.
|
|
|
|
*
|
|
|
|
* https://github.com/mamoe/mirai/blob/master/LICENSE
|
|
|
|
*/
|
|
|
|
|
2021-01-28 11:59:15 +08:00
|
|
|
@file:Suppress("ObjectPropertyName", "ObjectPropertyName", "unused", "MemberVisibilityCanBePrivate")
|
2020-11-22 14:25:49 +08:00
|
|
|
|
|
|
|
import org.gradle.api.attributes.Attribute
|
|
|
|
|
2020-03-24 10:01:03 +08:00
|
|
|
object Versions {
|
2021-08-31 11:15:24 +08:00
|
|
|
const val project = "2.8.0-M1"
|
2021-01-28 11:59:15 +08:00
|
|
|
|
2021-01-28 09:32:23 +08:00
|
|
|
const val core = project
|
|
|
|
const val console = project
|
|
|
|
const val consoleTerminal = project
|
2020-10-03 13:35:05 +08:00
|
|
|
|
2021-05-27 14:39:13 +08:00
|
|
|
const val kotlinCompiler = "1.5.10"
|
|
|
|
const val kotlinStdlib = "1.5.10"
|
|
|
|
const val dokka = "1.4.32"
|
2021-01-12 18:57:42 +08:00
|
|
|
|
2021-05-27 14:39:13 +08:00
|
|
|
const val coroutines = "1.5.0"
|
|
|
|
const val atomicFU = "0.16.1"
|
2021-07-02 22:39:56 +08:00
|
|
|
const val serialization = "1.2.1"
|
2021-05-27 14:39:13 +08:00
|
|
|
const val ktor = "1.5.4"
|
2020-10-03 13:35:05 +08:00
|
|
|
|
2021-02-24 12:15:19 +08:00
|
|
|
const val binaryValidator = "0.4.0"
|
2020-10-03 13:35:05 +08:00
|
|
|
|
|
|
|
const val io = "0.1.16"
|
|
|
|
const val coroutinesIo = "0.1.16"
|
|
|
|
|
2021-03-18 12:36:53 +08:00
|
|
|
const val blockingBridge = "1.10.3"
|
2020-10-03 13:35:05 +08:00
|
|
|
|
2021-02-01 12:23:04 +08:00
|
|
|
const val androidGradlePlugin = "4.1.1"
|
|
|
|
const val android = "4.1.1.4"
|
2020-10-03 13:35:05 +08:00
|
|
|
|
2021-01-21 10:08:21 +08:00
|
|
|
const val shadow = "6.1.0"
|
2020-10-03 13:35:05 +08:00
|
|
|
|
2021-08-09 23:45:32 +08:00
|
|
|
const val logback = "1.2.5"
|
|
|
|
const val slf4j = "1.7.32"
|
2021-08-06 02:31:17 +08:00
|
|
|
const val log4j = "2.14.1"
|
2021-02-25 00:12:58 +08:00
|
|
|
const val asm = "9.1"
|
2021-04-05 22:41:26 +08:00
|
|
|
const val difflib = "1.3.0"
|
2021-04-13 00:23:27 +08:00
|
|
|
const val netty = "4.1.63.Final"
|
2021-08-25 15:07:56 +08:00
|
|
|
const val bouncycastle = "1.64"
|
2021-01-28 09:32:23 +08:00
|
|
|
|
2021-05-20 19:45:33 +08:00
|
|
|
const val junit = "5.7.2"
|
2021-01-29 07:44:22 +08:00
|
|
|
|
|
|
|
// If you the versions below, you need to sync changes to mirai-console/buildSrc/src/main/kotlin/Versions.kt
|
|
|
|
|
2021-08-25 15:31:50 +08:00
|
|
|
const val yamlkt = "0.10.2"
|
2021-07-02 02:07:07 +08:00
|
|
|
const val intellijGradlePlugin = "1.1"
|
|
|
|
const val kotlinIntellijPlugin = "211-1.5.20-release-284-IJ7442.40" // keep to newest as kotlinCompiler
|
|
|
|
const val intellij = "2021.1.3" // don't update easily unless you want your disk space -= 500MB
|
2021-01-28 09:32:23 +08:00
|
|
|
|
2020-03-24 10:01:03 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
@Suppress("unused")
|
2020-03-24 18:11:14 +08:00
|
|
|
fun kotlinx(id: String, version: String) = "org.jetbrains.kotlinx:kotlinx-$id:$version"
|
2020-03-24 10:01:03 +08:00
|
|
|
|
|
|
|
@Suppress("unused")
|
2020-10-03 13:35:05 +08:00
|
|
|
fun ktor(id: String, version: String = Versions.ktor) = "io.ktor:ktor-$id:$version"
|
|
|
|
|
|
|
|
|
|
|
|
val `kotlinx-coroutines-core` = kotlinx("coroutines-core", Versions.coroutines)
|
2021-01-11 18:36:04 +08:00
|
|
|
val `kotlinx-coroutines-jdk8` = kotlinx("coroutines-jdk8", Versions.coroutines)
|
2021-03-19 23:12:02 +08:00
|
|
|
val `kotlinx-coroutines-swing` = kotlinx("coroutines-swing", Versions.coroutines)
|
2021-06-08 12:25:08 +08:00
|
|
|
val `kotlinx-coroutines-debug` = kotlinx("coroutines-debug", Versions.coroutines)
|
2020-10-03 13:35:05 +08:00
|
|
|
val `kotlinx-serialization-core` = kotlinx("serialization-core", Versions.serialization)
|
|
|
|
val `kotlinx-serialization-json` = kotlinx("serialization-json", Versions.serialization)
|
|
|
|
val `kotlinx-serialization-protobuf` = kotlinx("serialization-protobuf", Versions.serialization)
|
|
|
|
const val `kotlinx-atomicfu` = "org.jetbrains.kotlinx:atomicfu:${Versions.atomicFU}"
|
|
|
|
val `kotlinx-io` = kotlinx("io", Versions.io)
|
|
|
|
val `kotlinx-io-jvm` = kotlinx("io-jvm", Versions.io)
|
|
|
|
val `kotlinx-coroutines-io` = kotlinx("coroutines-io", Versions.coroutinesIo)
|
|
|
|
val `kotlinx-coroutines-io-jvm` = kotlinx("coroutines-io-jvm", Versions.coroutinesIo)
|
|
|
|
|
|
|
|
val `ktor-serialization` = ktor("serialization", Versions.ktor)
|
|
|
|
|
|
|
|
val `ktor-client-core` = ktor("client-core", Versions.ktor)
|
|
|
|
val `ktor-client-cio` = ktor("client-cio", Versions.ktor)
|
2020-12-28 15:04:19 +08:00
|
|
|
val `ktor-client-okhttp` = ktor("client-okhttp", Versions.ktor)
|
2020-10-03 13:35:05 +08:00
|
|
|
val `ktor-client-android` = ktor("client-android", Versions.ktor)
|
2021-08-06 02:31:17 +08:00
|
|
|
val `ktor-client-logging` = ktor("client-logging", Versions.ktor)
|
2020-10-03 13:35:05 +08:00
|
|
|
val `ktor-network` = ktor("network", Versions.ktor)
|
|
|
|
val `ktor-client-serialization-jvm` = ktor("client-serialization-jvm", Versions.ktor)
|
|
|
|
|
2021-08-09 23:45:32 +08:00
|
|
|
const val `logback-classic` = "ch.qos.logback:logback-classic:" + Versions.logback
|
|
|
|
|
2021-08-06 02:31:17 +08:00
|
|
|
const val `slf4j-api` = "org.slf4j:slf4j-api:" + Versions.slf4j
|
2021-04-17 16:13:16 +08:00
|
|
|
const val `slf4j-simple` = "org.slf4j:slf4j-simple:" + Versions.slf4j
|
2021-08-09 23:45:32 +08:00
|
|
|
|
2020-11-22 14:25:49 +08:00
|
|
|
const val `log4j-api` = "org.apache.logging.log4j:log4j-api:" + Versions.log4j
|
2021-08-06 02:31:17 +08:00
|
|
|
const val `log4j-core` = "org.apache.logging.log4j:log4j-core:" + Versions.log4j
|
|
|
|
const val `log4j-slf4j-impl` = "org.apache.logging.log4j:log4j-slf4j-impl:" + Versions.log4j
|
2021-08-09 23:45:32 +08:00
|
|
|
const val `log4j-to-slf4j` = "org.apache.logging.log4j:log4j-to-slf4j:" + Versions.log4j
|
2020-11-22 14:25:49 +08:00
|
|
|
|
2021-01-28 09:32:23 +08:00
|
|
|
val ATTRIBUTE_MIRAI_TARGET_PLATFORM: Attribute<String> = Attribute.of("mirai.target.platform", String::class.java)
|
|
|
|
|
|
|
|
|
|
|
|
const val `kotlin-compiler` = "org.jetbrains.kotlin:kotlin-compiler:${Versions.kotlinCompiler}"
|
|
|
|
|
|
|
|
const val `kotlin-stdlib` = "org.jetbrains.kotlin:kotlin-stdlib:${Versions.kotlinStdlib}"
|
|
|
|
const val `kotlin-stdlib-jdk8` = "org.jetbrains.kotlin:kotlin-stdlib-jdk8:${Versions.kotlinStdlib}"
|
|
|
|
const val `kotlin-reflect` = "org.jetbrains.kotlin:kotlin-reflect:${Versions.kotlinStdlib}"
|
|
|
|
const val `kotlin-test` = "org.jetbrains.kotlin:kotlin-test:${Versions.kotlinStdlib}"
|
|
|
|
const val `kotlin-test-junit5` = "org.jetbrains.kotlin:kotlin-test-junit5:${Versions.kotlinStdlib}"
|
|
|
|
|
|
|
|
|
|
|
|
const val `mirai-core-api` = "net.mamoe:mirai-core-api:${Versions.core}"
|
|
|
|
const val `mirai-core` = "net.mamoe:mirai-core:${Versions.core}"
|
|
|
|
const val `mirai-core-utils` = "net.mamoe:mirai-core-utils:${Versions.core}"
|
|
|
|
|
|
|
|
const val yamlkt = "net.mamoe.yamlkt:yamlkt:${Versions.yamlkt}"
|
|
|
|
|
|
|
|
const val `jetbrains-annotations` = "org.jetbrains:annotations:19.0.0"
|
|
|
|
|
|
|
|
|
2021-02-15 10:42:37 +08:00
|
|
|
const val `caller-finder` = "io.github.karlatemp:caller:1.1.1"
|
2021-02-01 12:23:04 +08:00
|
|
|
|
2021-04-13 00:23:27 +08:00
|
|
|
const val `android-runtime` = "com.google.android:android:${Versions.android}"
|
2021-08-25 15:07:56 +08:00
|
|
|
const val `netty-all` = "io.netty:netty-all:${Versions.netty}"
|
|
|
|
const val `bouncycastle` = "org.bouncycastle:bcprov-jdk15on:${Versions.bouncycastle}"
|