diff --git a/gradle.properties b/gradle.properties index 68ea555d2..038305b04 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,16 +1,16 @@ # style guide kotlin.code.style=official # config -miraiVersion=0.24.1 +miraiVersion=0.26.1 miraiConsoleVersion=0.3.2 -miraiConsoleWrapperVersion=0.1.1 +miraiConsoleWrapperVersion=0.1.2 kotlin.incremental.multiplatform=true kotlin.parallel.tasks.in.project=true # kotlin -kotlinVersion=1.3.61 +kotlinVersion=1.3.70 # kotlin libraries -serializationVersion=0.14.0 -coroutinesVersion=1.3.3 +serializationVersion=0.20.0 +coroutinesVersion=1.3.4 atomicFuVersion=0.14.1 kotlinXIoVersion=0.1.16 coroutinesIoVersion=0.1.16 diff --git a/mirai-console-wrapper/build.gradle.kts b/mirai-console-wrapper/build.gradle.kts index 5db44134b..b1f424712 100644 --- a/mirai-console-wrapper/build.gradle.kts +++ b/mirai-console-wrapper/build.gradle.kts @@ -8,6 +8,7 @@ val kotlinVersion: String by rootProject.ext val coroutinesVersion: String by rootProject.ext val coroutinesIoVersion: String by rootProject.ext val atomicFuVersion: String by rootProject.ext +val kotlinXIoVersion: String by rootProject.ext val ktorVersion: String by rootProject.ext @@ -38,37 +39,47 @@ kotlin { val serializationVersion: String by rootProject.ext dependencies { + //core && protocol api(kotlin("stdlib", kotlinVersion)) + api(kotlin("serialization", kotlinVersion)) + api(kotlin("reflect", kotlinVersion)) + api(kotlinx("coroutines-core-common", coroutinesVersion)) + api(kotlinx("serialization-runtime-common", serializationVersion)) + api(kotlinx("serialization-protobuf-common", serializationVersion)) + api(kotlinx("io", kotlinXIoVersion)) + api(kotlinx("coroutines-io", coroutinesIoVersion)) api(kotlinx("coroutines-core", coroutinesVersion)) - api(ktor("client-core-jvm", ktorVersion)) - api(ktor("client-cio", ktorVersion)) - api(kotlin("reflect")) + api("org.jetbrains.kotlinx:atomicfu-common:$atomicFuVersion") + api(ktor("client-cio", ktorVersion)) + api(ktor("client-core", ktorVersion)) + api(ktor("network", ktorVersion)) + api(kotlin("reflect", kotlinVersion)) + + api(ktor("client-core-jvm", ktorVersion)) + api(kotlinx("io-jvm", kotlinXIoVersion)) + api(kotlinx("serialization-runtime", serializationVersion)) + api(kotlinx("serialization-protobuf", serializationVersion)) + api(kotlinx("coroutines-io-jvm", coroutinesIoVersion)) + api(kotlinx("coroutines-core", coroutinesVersion)) + + api("org.bouncycastle:bcprov-jdk15on:1.64") + + api("org.jetbrains.kotlinx:atomicfu:$atomicFuVersion") + api(kotlinx("serialization-runtime-common", serializationVersion)) + api(kotlinx("serialization-protobuf-common", serializationVersion)) + api(kotlinx("serialization-runtime", serializationVersion)) + + //for slf4j[ktor used] + api(group = "org.apache.cassandra", name = "cassandra-all", version = "0.8.1") + + //mirai-console api(group = "com.alibaba", name = "fastjson", version = "1.2.62") api(group = "org.yaml", name = "snakeyaml", version = "1.25") api(group = "com.moandjiezana.toml", name = "toml4j", version = "0.7.2") - - api(kotlin("stdlib", kotlinVersion)) - api(kotlin("serialization", kotlinVersion)) - - api(kotlin("reflect", kotlinVersion)) - - api(kotlinx("coroutines-io-jvm", coroutinesIoVersion)) - api(kotlinx("coroutines-core", coroutinesVersion)) - api(kotlinx("serialization-runtime", serializationVersion)) - api("org.jetbrains.kotlinx:atomicfu:$atomicFuVersion") - - api("org.bouncycastle:bcprov-jdk15on:1.64") - - api(ktor("http-cio", ktorVersion)) - api(ktor("http-jvm", ktorVersion)) - api(ktor("io-jvm", ktorVersion)) - api(ktor("client-core-jvm", ktorVersion)) - api(ktor("client-cio", ktorVersion)) - api(ktor("network", ktorVersion)) } val miraiConsoleWrapperVersion: String by project.ext diff --git a/mirai-console/build.gradle.kts b/mirai-console/build.gradle.kts index 150eaf874..27e56ba56 100644 --- a/mirai-console/build.gradle.kts +++ b/mirai-console/build.gradle.kts @@ -40,7 +40,7 @@ kotlin { } dependencies { compileOnly("net.mamoe:mirai-core-jvm:$miraiVersion") - // compileOnly("net.mamoe:mirai-core-qqandroid-jvm:$miraiVersion") + compileOnly("net.mamoe:mirai-core-qqandroid-jvm:$miraiVersion") compileOnly(group = "com.alibaba", name = "fastjson", version = "1.2.62") diff --git a/mirai-console/src/main/kotlin/net/mamoe/mirai/console/plugins/PluginManager.kt b/mirai-console/src/main/kotlin/net/mamoe/mirai/console/plugins/PluginManager.kt index 0359249b8..835359395 100644 --- a/mirai-console/src/main/kotlin/net/mamoe/mirai/console/plugins/PluginManager.kt +++ b/mirai-console/src/main/kotlin/net/mamoe/mirai/console/plugins/PluginManager.kt @@ -222,7 +222,6 @@ object PluginManager { } logger.info("""加载了${nameToPluginBaseMap.size}个插件""") - } @@ -270,4 +269,5 @@ object PluginManager { jar.entries().asSequence().filter { it.name == toFind }.firstOrNull() ?: return null return URL("jar:file:" + jarFile.absoluteFile + "!/" + toFindFile.name).openConnection().inputStream } + }