Skip to content

Commit

Permalink
Remove local library (via ./libs) support
Browse files Browse the repository at this point in the history
  • Loading branch information
Cadiboo committed Feb 4, 2024
1 parent 2c74ae6 commit f29b931
Showing 1 changed file with 0 additions and 13 deletions.
13 changes: 0 additions & 13 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -103,24 +103,11 @@ repositories {
}
}
dependencies {
// If OptiFine (deobfuscated with Cadiboo's OptiFine deobf tool) is in libs, we want to be able to look at its classes
// We use 'testCompileOnly' and not 'implementation', we don't want it to actually load at runtime because the non-deobf
// version of OptiFine and OptiFineDevTweaker are loaded from the mods folder at runtime
// OptiFine is the first dependency because so that we can compile against its version of vanilla's classes, not Forge's
testCompileOnly fileTree(include: ['OptiFine_*_MOD-deobf.jar'], dir: 'libs')

minecraft "net.minecraftforge:forge:${modMinecraftVersion}-${modForgeVersion}"

// Apply Mixin AP
annotationProcessor 'org.spongepowered:mixin:0.8.5:processor'

// Add a compile/implementation dependency on (and deobfuscate) all .jar files in ./libs
fileTree(include: ['*.jar'], exclude: ['OptiFine_*_MOD-deobf.jar'], dir: 'libs').each { file ->
def fileNameWithoutDotJarExtension = file.name.substring(0, file.name.length() - 4)
def indexOfLastDash = fileNameWithoutDotJarExtension.lastIndexOf('-');
implementation fg.deobf("local:${fileNameWithoutDotJarExtension.substring(0, indexOfLastDash)}:${fileNameWithoutDotJarExtension.substring(indexOfLastDash + 1)}")
}

// For the config color picker (we include it in our production jar with ShadowJar)
library 'org.beryx:awt-color-factory:1.0.2'

Expand Down

0 comments on commit f29b931

Please sign in to comment.