-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathbuild.gradle.kts
57 lines (48 loc) · 1.61 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
plugins {
id("dev.architectury.loom")
id("architectury-plugin")
}
val minecraft = stonecutter.current.version
version = "${mod.version}+$minecraft"
base {
archivesName.set("${mod.id}-common")
}
architectury.common(stonecutter.tree.branches.mapNotNull {
if (stonecutter.current.project !in it) null
else it.prop("loom.platform")
})
repositories {
maven ( "https://api.modrinth.com/maven")
maven ( "https://maven2.bai.lol" )
}
dependencies {
minecraft("com.mojang:minecraft:$minecraft")
mappings("net.fabricmc:yarn:$minecraft+build.${mod.dep("yarn_build")}:v2")
modImplementation("net.fabricmc:fabric-loader:${mod.dep("fabric_loader")}")
"io.github.llamalad7:mixinextras-common:${mod.dep("mixin_extras")}".let {
annotationProcessor(it)
implementation(it)
}
modApi("me.shedaniel.cloth:cloth-config-fabric:${mod.dep("cloth_version")}")
modCompileOnly("maven.modrinth:jade:${mod.dep("jade_fabric_version")}")
modCompileOnly("mcp.mobius.waila:wthit-api:fabric-${mod.dep("wthit_version")}")
modCompileOnly("maven.modrinth:useful-spyglass:${mod.dep("useful_spyglass")}-fabric")
}
loom {
decompilers {
get("vineflower").apply { // Adds names to lambdas - useful for mixins
options.put("mark-corresponding-synthetics", "1")
}
}
}
java {
withSourcesJar()
val java = if (stonecutter.eval(minecraft, ">=1.20.5"))
JavaVersion.VERSION_21 else JavaVersion.VERSION_17
targetCompatibility = java
sourceCompatibility = java
}
tasks.build {
group = "versioned"
description = "Must run through 'chiseledBuild'"
}