Skip to content

Commit

Permalink
Exclude from relocation, not inclusion
Browse files Browse the repository at this point in the history
  • Loading branch information
Kas-tle committed Aug 24, 2022
1 parent e35f378 commit dc29d99
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions bootstrap/spigot/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ dependencies {

platformRelocate("it.unimi.dsi.fastutil")
platformRelocate("com.fasterxml.jackson")
platformRelocate("net.kyori")
platformRelocate("net.kyori", "net.kyori.adventure.text.logger.slf4j.ComponentLogger")
platformRelocate("org.objectweb.asm")
platformRelocate("me.lucko.commodore")
platformRelocate("io.netty.channel.kqueue")
Expand Down Expand Up @@ -65,6 +65,6 @@ tasks.withType<com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar> {
exclude(dependency("com.mojang:.*"))

// Adventure slf4j
exclude(dependency("net.kyori.adventure.text.logger.slf4j:ComponentLogger"))
//exclude(dependency("net.kyori.adventure.text.logger.slf4j:ComponentLogger"))
}
}
6 changes: 4 additions & 2 deletions build-logic/src/main/kotlin/extensions.kt
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,11 @@ fun Project.exclude(group: String) {
}
}

fun Project.platformRelocate(pattern: String) {
fun Project.platformRelocate(pattern: String, exclusion: String = "") {
tasks.named<ShadowJar>("shadowJar") {
relocate(pattern, "org.geysermc.geyser.platform.${project.name}.shaded.$pattern")
relocate(pattern, "org.geysermc.geyser.platform.${project.name}.shaded.$pattern") {
exclude(exclusion)
}
}
}

Expand Down

0 comments on commit dc29d99

Please sign in to comment.