This repository was archived by the owner on Dec 10, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 6 files changed +37
-28
lines changed
surf-cloud-standalone/src/main/kotlin/dev/slne/surf/cloud/standalone Expand file tree Collapse file tree 6 files changed +37
-28
lines changed Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ dependencies {
1111// val kotlinVersion = "2.1.0"
1212// val dokkaVersion = "2.0.0-Beta"
1313
14- implementation(" org.springframework.boot:org.springframework.boot.gradle.plugin:3.5.3 " )
14+ implementation(" org.springframework.boot:org.springframework.boot.gradle.plugin:3.5.6 " )
1515// implementation("org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion")
1616// implementation("org.jetbrains.kotlin:kotlin-allopen:$kotlinVersion")
1717// implementation("org.jetbrains.kotlin:kotlin-lombok:$kotlinVersion")
Original file line number Diff line number Diff line change 11[versions ]
22velocity-version = " 3.4.0-SNAPSHOT"
33aide-reflection = " 1.3"
4- netty = " 4.2.3 .Final"
5- netty-tcnative = " 2.0.72 .Final"
4+ netty = " 4.2.6 .Final"
5+ netty-tcnative = " 2.0.74 .Final"
66datafixerupper = " 8.0.16"
77# byte-buddy = "1.15.10"
88exposed = " 0.61.0"
99maven-impl = " 4.0.0-rc-2"
1010maven-resolver = " 2.0.5"
11- jline = " 3.30.4 "
11+ jline = " 3.30.6 "
1212brigadier = " 1.3.10"
1313terminalconsoleappender = " 1.3.0"
1414bson-kotlinx = " 5.4.0"
1515aspectjweaver = " 1.9.22.1"
1616zstd-jni = " 1.5.7-4"
17- luckperms-api = " 5.4 "
17+ luckperms-api = " 5.5 "
1818reactive-streams = " 1.0.4"
1919ehcache = " 3.10.8"
2020kotlin-byte-buf-serializer = " 1.1.0"
21- voicechat-api = " 2.5.27 "
21+ voicechat-api = " 2.6.0 "
2222discord-webhooks = " 1.0"
2323konf = " 1.1.2"
2424
Original file line number Diff line number Diff line change @@ -30,7 +30,7 @@ import java.util.*
3030class PluginCommand : AbstractConsoleCommand () {
3131
3232 override fun register (dispatcher : CommandDispatcher <CommandSource >) {
33- val root = literal<CommandSource >(" plugins" ) {
33+ val root = dispatcher.register( literal<CommandSource >(" plugins" ) {
3434 executes { ctx ->
3535 val plugins =
3636 TreeMap <String , PluginProvider <StandalonePlugin >>(String .CASE_INSENSITIVE_ORDER )
@@ -57,12 +57,9 @@ class PluginCommand : AbstractConsoleCommand() {
5757 ctx.source.sendMessage(infoMessage)
5858 Command .SINGLE_SUCCESS
5959 }
60- }
61-
62- dispatcher.register(root)
63- dispatcher.register(literal(" pl" ) {
64- redirect(root.build())
6560 })
61+
62+ dispatcher.register(literal(" pl" ) { redirect(root) })
6663 }
6764
6865 private fun <T > formatProviders (plugins : TreeMap <String , PluginProvider <T >>): List <Component > {
Original file line number Diff line number Diff line change @@ -53,7 +53,6 @@ private object YamlConfigParser : ConfigParser {
5353
5454object CloudServerConfigProvider : ServerConfigProvider(
5555 mapOf(
56- "standalone-config.yml" to YamlConfigParser ,
5756 "config.yml" to YamlConfigParser ,
5857 ),
5958 listOf(
Original file line number Diff line number Diff line change 1+ package dev.slne.surf.cloud.standalone.spring
2+
3+ import com.google.auto.service.AutoService
4+ import dev.slne.surf.cloud.core.common.spring.CloudSpringApplicationConfiguration
5+ import dev.slne.surf.cloud.standalone.config.StandaloneConfigHolder
6+ import org.flywaydb.core.api.configuration.FluentConfiguration
7+ import org.springframework.boot.autoconfigure.flyway.FlywayConfigurationCustomizer
8+ import org.springframework.boot.builder.SpringApplicationBuilder
9+ import org.springframework.context.annotation.Profile
10+ import org.springframework.stereotype.Component
11+
12+ @AutoService(CloudSpringApplicationConfiguration ::class )
13+ class FlywayConfigurer : CloudSpringApplicationConfiguration {
14+ override fun configureApplication (builder : SpringApplicationBuilder ) {
15+ if (! StandaloneConfigHolder .isFlywayEnabled()) {
16+ builder.properties(" spring.flyway.enabled=false" )
17+ }
18+ }
19+
20+ @Component
21+ @Profile(" !plugin" )
22+ class Customizer (private val configHolder : StandaloneConfigHolder ) :
23+ FlywayConfigurationCustomizer {
24+ override fun customize (configuration : FluentConfiguration ) {
25+ configuration.baselineOnMigrate(configHolder.config.connectionConfig.databaseConfig.flyway.baselineOnMigrate)
26+ }
27+ }
28+ }
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments