mirror of
https://github.com/mamoe/mirai.git
synced 2025-03-28 16:50:09 +08:00
Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
757a960236
@ -11,7 +11,7 @@ import org.gradle.kotlin.dsl.DependencyHandlerScope
|
|||||||
|
|
||||||
object Versions {
|
object Versions {
|
||||||
object Mirai {
|
object Mirai {
|
||||||
const val core = "0.34.0"
|
const val core = "0.37.1"
|
||||||
const val console = "0.4.8"
|
const val console = "0.4.8"
|
||||||
const val consoleGraphical = "0.0.7"
|
const val consoleGraphical = "0.0.7"
|
||||||
const val consoleWrapper = "0.2.0"
|
const val consoleWrapper = "0.2.0"
|
||||||
|
@ -50,7 +50,7 @@ bintray {
|
|||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compileOnly("net.mamoe:mirai-core-jvm:${Versions.Mirai.core}")
|
compileOnly("net.mamoe:mirai-core:${Versions.Mirai.core}")
|
||||||
implementation(project(":mirai-console"))
|
implementation(project(":mirai-console"))
|
||||||
|
|
||||||
api(group = "no.tornado", name = "tornadofx", version = "1.7.19")
|
api(group = "no.tornado", name = "tornadofx", version = "1.7.19")
|
||||||
@ -59,7 +59,8 @@ dependencies {
|
|||||||
testApi(project(":mirai-console"))
|
testApi(project(":mirai-console"))
|
||||||
testApi(kotlinx("coroutines-core", Versions.Kotlin.coroutines))
|
testApi(kotlinx("coroutines-core", Versions.Kotlin.coroutines))
|
||||||
testApi(group = "org.yaml", name = "snakeyaml", version = "1.25")
|
testApi(group = "org.yaml", name = "snakeyaml", version = "1.25")
|
||||||
testApi("net.mamoe:mirai-core-jvm:${Versions.Mirai.core}")
|
testApi("net.mamoe:mirai-core:${Versions.Mirai.core}")
|
||||||
|
testApi("net.mamoe:mirai-core-qqandroid:${Versions.Mirai.core}")
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
|
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
|
||||||
|
@ -22,7 +22,7 @@ kotlin {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
compileOnly("net.mamoe:mirai-core-jvm:${Versions.Mirai.core}")
|
compileOnly("net.mamoe:mirai-core:${Versions.Mirai.core}")
|
||||||
compileOnly(kotlin("stdlib")) // embedded by core
|
compileOnly(kotlin("stdlib")) // embedded by core
|
||||||
|
|
||||||
api("com.google.code.gson:gson:2.8.6")
|
api("com.google.code.gson:gson:2.8.6")
|
||||||
@ -30,7 +30,7 @@ dependencies {
|
|||||||
api(group = "com.moandjiezana.toml", name = "toml4j", version = "0.7.2")
|
api(group = "com.moandjiezana.toml", name = "toml4j", version = "0.7.2")
|
||||||
api("org.jsoup:jsoup:1.12.1")
|
api("org.jsoup:jsoup:1.12.1")
|
||||||
|
|
||||||
testApi("net.mamoe:mirai-core-qqandroid-jvm:${Versions.Mirai.core}")
|
testApi("net.mamoe:mirai-core-qqandroid:${Versions.Mirai.core}")
|
||||||
testApi(kotlin("stdlib"))
|
testApi(kotlin("stdlib"))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -159,7 +159,7 @@ object PluginManager {
|
|||||||
/**
|
/**
|
||||||
* 尝试加载全部插件
|
* 尝试加载全部插件
|
||||||
*/
|
*/
|
||||||
fun loadPlugins() {
|
fun loadPlugins(clear: Boolean = true) {
|
||||||
logger.info("""开始加载${pluginsPath}下的插件""")
|
logger.info("""开始加载${pluginsPath}下的插件""")
|
||||||
val findPluginsResult = findPlugins()
|
val findPluginsResult = findPlugins()
|
||||||
val pluginsFound = findPluginsResult.pluginsFound
|
val pluginsFound = findPluginsResult.pluginsFound
|
||||||
@ -249,8 +249,10 @@ object PluginManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//清掉优先级队列, 来重新填充
|
if (clear) {
|
||||||
pluginsSequence.clear()
|
//清掉优先级队列, 来重新填充
|
||||||
|
pluginsSequence.clear()
|
||||||
|
}
|
||||||
|
|
||||||
pluginsFound.values.forEach {
|
pluginsFound.values.forEach {
|
||||||
try {
|
try {
|
||||||
@ -341,7 +343,7 @@ object PluginManager {
|
|||||||
disablePlugin(it)
|
disablePlugin(it)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
loadPlugins()
|
loadPlugins(false)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user