mirror of
https://github.com/BlueMap-Minecraft/BlueMap.git
synced 2024-11-26 04:25:31 +01:00
include dependencies with new task
This commit is contained in:
parent
c61c984d6f
commit
e1370c8157
@ -1,3 +1,5 @@
|
||||
import net.fabricmc.loom.task.RemapJarTask
|
||||
|
||||
plugins {
|
||||
id 'fabric-loom' version '0.2.7-SNAPSHOT'
|
||||
}
|
||||
@ -12,7 +14,7 @@ dependencies {
|
||||
modImplementation "net.fabricmc:fabric-loader:0.8.2+build.194"
|
||||
modImplementation "net.fabricmc.fabric-api:fabric-api:0.5.1+build.294-1.15"
|
||||
|
||||
include (project(':BlueMapCommon')) {
|
||||
compile (project(':BlueMapCommon')) {
|
||||
//exclude dependencies provided by fabric
|
||||
exclude group: 'com.google.guava', module: 'guava'
|
||||
exclude group: 'com.google.code.gson', module: 'gson'
|
||||
@ -22,19 +24,6 @@ dependencies {
|
||||
}
|
||||
}
|
||||
|
||||
build.dependsOn shadowJar {
|
||||
destinationDir = file '../build/unsupported'
|
||||
archiveFileName = "BlueMap-${version}-fabric.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 {
|
||||
inputs.property "version", project.version
|
||||
|
||||
@ -48,6 +37,32 @@ processResources {
|
||||
}
|
||||
}
|
||||
|
||||
shadowJar {
|
||||
configurations = [project.configurations.compile]
|
||||
|
||||
dependencies {
|
||||
include(dependency(':BlueMapCommon'))
|
||||
include(dependency(':BlueMapCore'))
|
||||
include(dependency(':BlueMapAPI'))
|
||||
}
|
||||
|
||||
//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'
|
||||
|
||||
exclude '/mappings/*'
|
||||
}
|
||||
|
||||
task ramappedShadowJar(type: RemapJarTask) {
|
||||
destinationDir = file '../build/unsupported'
|
||||
dependsOn tasks.shadowJar
|
||||
input = tasks.shadowJar.archivePath
|
||||
addNestedDependencies = true
|
||||
archiveName = "BlueMap-${version}-fabric.jar"
|
||||
}
|
||||
|
||||
task sourcesJar(type: Jar, dependsOn: classes) {
|
||||
classifier = "sources"
|
||||
from sourceSets.main.allSource
|
||||
|
Loading…
Reference in New Issue
Block a user