BlueMap/BlueMapForge/build.gradle
2020-07-30 16:45:22 +02:00

65 lines
1.7 KiB
Groovy

buildscript {
repositories {
maven { url = 'https://files.minecraftforge.net/maven/' }
jcenter()
mavenCentral()
}
dependencies {
classpath group: 'net.minecraftforge.gradle', name: 'ForgeGradle', version: '3.+', changing: true
}
}
apply plugin: 'net.minecraftforge.gradle'
minecraft {
mappings channel: 'snapshot', version: '20200514-1.16'
}
configurations {
compile.extendsFrom include
}
dependencies {
minecraft 'net.minecraftforge:forge:1.16.1-32.0.97'
include (project(':BlueMapCommon')) {
//exclude dependencies provided by forge
exclude group: 'com.google.guava', module: 'guava'
exclude group: 'com.google.code.gson', module: 'gson'
exclude group: 'org.apache.commons', module: 'commons-lang3'
exclude group: 'commons-io', module: 'commons-io'
exclude group: 'com.mojang', module: 'brigadier'
}
}
build.dependsOn shadowJar {
destinationDir = file '../build/release'
archiveFileName = "BlueMap-${version}-forge.jar"
configurations = [project.configurations.include]
//relocate 'com.flowpowered.math', 'de.bluecolored.shadow.flowpowered.math' //DON'T relocate this, because the API depends on it
relocate 'com.typesafe.config', 'de.bluecolored.shadow.typesafe.config'
relocate 'net.querz.nbt', 'de.bluecolored.shadow.querz.nbt'
relocate 'ninja.leaping.configurate', 'de.bluecolored.shadow.ninja.leaping.configurate'
relocate 'org.yaml.snakeyaml', 'de.bluecolored.shadow.yaml.snakeyaml'
}
processResources {
from(sourceSets.main.resources.srcDirs) {
include 'mcmod.info','META-INF/mods.toml'
expand (
version: project.version
)
}
}
afterEvaluate {
reobf {
shadowJar {
mappings = createMcpToSrg.output
}
}
}