Skip to content

Commit

Permalink
Fix shadowing
Browse files Browse the repository at this point in the history
  • Loading branch information
embeddedt committed May 21, 2024
1 parent 9a8aa19 commit b144a7a
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -84,15 +84,10 @@ listOf(configurations.runtimeClasspath, configurations.testRuntimeClasspath).for
}
}

val embed: Configuration by configurations.creating {
description = "Included in output JAR"
}

val shadow = configurations.getByName("shadow")

listOf(configurations.implementation).forEach {
it.configure {
extendsFrom(embed)
extendsFrom(shadow)
}
}
Expand Down Expand Up @@ -151,7 +146,7 @@ dependencies {
compileOnly(rfg.deobf("curse.maven:opencomputers-223008:4566834"))
compileOnly(rfg.deobf("curse.maven:extrautils-225561:2678374"))
compileOnly(rfg.deobf("curse.maven:chiselsandbits-231095:2720655"))
embed("com.esotericsoftware:kryo:5.1.1")
shadow("com.esotericsoftware:kryo:5.1.1")
val mixinExtras = "io.github.llamalad7:mixinextras-common:0.3.6"
shadow(mixinExtras)
annotationProcessor(mixinExtras)
Expand All @@ -176,7 +171,7 @@ val refMap = mixinTmpDir + File.separator + mixinConfigRefMap
val mixinSrg = mixinTmpDir + File.separator + "mixins.srg"

tasks.withType<ShadowJar> {
configurations.add(shadow)
configurations = listOf(shadow)
relocate("com.llamalad7.mixinextras", "org.embeddedt.vintagefix.mixinextras")
mergeServiceFiles() // Very important!
}
Expand Down Expand Up @@ -224,7 +219,6 @@ tasks.named<Jar>("jar") {
}
}
from(googleimpl.output)
from(provider { configurations["embed"].map { if (it.isDirectory) it else zipTree(it) } })
}

val copyJarToBin = tasks.register<Copy>("copyJarToBin") {
Expand Down

0 comments on commit b144a7a

Please sign in to comment.