Files
architectury-loom/forge-runtime/build.gradle
shedaniel 728d1091dd AT Refactor
Signed-off-by: shedaniel <daniel@shedaniel.me>
2021-07-11 02:15:05 +08:00

87 lines
1.9 KiB
Groovy

plugins {
id 'java'
id 'maven-publish'
id 'checkstyle'
id 'com.github.johnrengelman.shadow'
id 'org.cadixdev.licenser'
}
group = rootProject.group
archivesBaseName = 'architectury-loom-forge-runtime'
version = rootProject.version
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
configurations {
include
compileOnly.extendsFrom include
}
tasks.withType(JavaCompile).configureEach {
it.options.encoding = "UTF-8"
}
repositories {
mavenCentral()
maven { url "https://maven.fabricmc.net/" }
maven { url "https://maven.minecraftforge.net/" }
}
dependencies {
// shadowed
include ('net.fabricmc:tiny-mappings-parser:0.3.0+build.17')
// guaranteed to be there at runtime
compileOnly ('cpw.mods:modlauncher:6.1.3')
compileOnly ('org.spongepowered:mixin:0.8.2')
compileOnly ('com.google.code.gson:gson:2.8.6')
compileOnly ('com.google.guava:guava:21.0')
compileOnly ('org.apache.logging.log4j:log4j-api:2.11.2')
}
jar {
classifier = "slim"
}
shadowJar {
classifier = ""
configurations = [project.configurations.include]
relocate "net.fabricmc.mapping", "dev.architectury.loom.forgeruntime.shadow.mapping"
relocate "net.fabricmc.mappings", "dev.architectury.loom.forgeruntime.shadow.mappings"
}
assemble.dependsOn shadowJar
license {
header rootProject.file("HEADER")
include "**/*.java"
exclude '**/loom/forgeruntime/mixin/MixinIntermediaryDevRemapper.java'
}
checkstyle {
configFile = rootProject.checkstyle.configFile
toolVersion = rootProject.checkstyle.toolVersion
}
publishing {
publications {
maven(MavenPublication) {
artifactId = 'architectury-loom-forge-runtime'
shadow.component it
}
}
repositories {
if (System.getenv("MAVEN_PASS") != null) {
maven {
url = "https://deploy.shedaniel.me/"
credentials {
username = "shedaniel"
password = System.getenv("MAVEN_PASS")
}
}
}
}
}