mirror of
https://github.com/darksaid98/Carbon.git
synced 2026-12-03 22:15:45 +00:00
Move dependency downloader code out of project
This commit is contained in:
1 parent
13c1e98872
commit
2ed9025101
13 files changed
+51
-517
No files matched your search
@@ -12,16 +12,11 @@ dependencies {
|
||||
implementation(libs.cloudVelocity)
|
||||
compileOnly(libs.miniplaceholders)
|
||||
|
||||
runtimeOnly(libs.jarRelocator)
|
||||
|
||||
runtimeDownload(libs.mysql)
|
||||
}
|
||||
|
||||
configurations.runtimeClasspath {
|
||||
resolutionStrategy.force(
|
||||
"org.ow2.asm:asm:9.6",
|
||||
"org.ow2.asm:asm-commons:9.6",
|
||||
)
|
||||
gremlin {
|
||||
defaultJarRelocatorDependencies.set(true)
|
||||
}
|
||||
|
||||
tasks {
|
||||
@@ -30,8 +25,6 @@ tasks {
|
||||
standardRuntimeRelocations()
|
||||
relocateDependency("com.google.inject.assistedinject")
|
||||
relocateDependency("io.leangen.geantyref")
|
||||
relocateDependency("me.lucko.jarrelocator")
|
||||
relocateDependency("org.objectweb.asm")
|
||||
}
|
||||
writeDependencies {
|
||||
standardRuntimeRelocations()
|
||||
|
||||
@@ -34,6 +34,7 @@ import net.draycia.carbon.common.util.CarbonDependencies;
|
||||
import org.bstats.charts.SimplePie;
|
||||
import org.bstats.velocity.Metrics;
|
||||
import org.checkerframework.checker.nullness.qual.MonotonicNonNull;
|
||||
import xyz.jpenilla.gremlin.runtime.platformsupport.VelocityClasspathAppender;
|
||||
|
||||
public final class CarbonVelocityBootstrap {
|
||||
|
||||
@@ -63,9 +64,8 @@ public final class CarbonVelocityBootstrap {
|
||||
|
||||
@Subscribe
|
||||
public void onProxyInitialize(final ProxyInitializeEvent event) {
|
||||
CarbonDependencies.load(
|
||||
this.dataDirectory.resolve("libraries"),
|
||||
path -> this.proxy.getPluginManager().addToClasspath(this, path)
|
||||
new VelocityClasspathAppender(this.proxy, this).append(
|
||||
CarbonDependencies.resolve(this.dataDirectory.resolve("libraries"))
|
||||
);
|
||||
|
||||
this.injector = this.parentInjector.createChildInjector(
|
||||
|
||||
Reference in new issue
Block a user