ntx4core/build.gradle

95 lines
2.6 KiB
Groovy
Raw Normal View History

2023-10-07 16:24:37 +02:00
plugins {
id "dev.architectury.loom" version "1.1-SNAPSHOT"
id "maven-publish"
}
sourceCompatibility = targetCompatibility = JavaVersion.VERSION_17
archivesBaseName = project.archives_base_name
version = project.mod_version
group = project.maven_group
loom {
forge {
mixinConfigs = [
"ntx4core.mixins.json"
]
}
}
2023-10-27 19:39:22 +02:00
repositories {
2023-10-30 18:20:54 +01:00
mavenLocal()
2023-12-05 22:17:51 +01:00
maven { url "https://maven.tilera.xyz/" }
maven { url "https://dl.cloudsmith.io/public/geckolib3/geckolib/maven/" }
maven { url "https://maven.blamejared.com" }
2023-10-27 19:39:22 +02:00
}
2023-10-07 16:24:37 +02:00
dependencies {
// to change the versions see the gradle.properties file
minecraft "com.mojang:minecraft:${project.minecraft_version}"
mappings "net.fabricmc:yarn:${project.yarn_mappings}:v2"
forge "net.minecraftforge:forge:${project.forge_version}"
2023-10-27 19:39:22 +02:00
modImplementation "software.bernie.geckolib:geckolib-forge-1.18:3.0.57"
2023-11-27 20:59:10 +01:00
modImplementation "net.anvilcraft:anvillib-18-forge:1.1.0"
2023-12-05 22:17:51 +01:00
modImplementation "vazkii.patchouli:Patchouli:1.18.2-66"
2023-10-07 16:24:37 +02:00
}
processResources {
// this will replace the property "${version}" in your mods.toml
// with the version you've defined in your gradle.properties
filesMatching("META-INF/mods.toml") {
expand "version": project.version
}
}
tasks.withType(JavaCompile) {
options.encoding = "UTF-8"
options.release = 17
}
java {
// Loom will automatically attach sourcesJar to a RemapSourcesJar task and to the "build" task
// if it is present.
// If you remove this line, sources will not be generated.
withSourcesJar()
}
jar {
// add some additional metadata to the jar manifest
manifest {
attributes([
"Specification-Title" : project.mod_id,
"Specification-Vendor" : project.mod_author,
"Specification-Version" : "1",
"Implementation-Title" : project.name,
"Implementation-Version" : version,
"Implementation-Vendor" : project.mod_author,
"Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ")
])
}
}
// configure the maven publication
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
}
}
2023-12-06 22:36:17 +01:00
repositories {
if (project.hasProperty("mvnURL")) {
maven {
credentials {
username findProperty("mvnUsername")
password findProperty("mvnPassword")
}
url = findProperty("mvnURL")
}
}
mavenLocal()
}
2023-10-07 16:24:37 +02:00
}