-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuild.gradle.kts
More file actions
53 lines (43 loc) · 1.32 KB
/
Copy pathbuild.gradle.kts
File metadata and controls
53 lines (43 loc) · 1.32 KB
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
plugins {
id("architectury-plugin") version "3.4-SNAPSHOT"
id("dev.architectury.loom") version "1.9-SNAPSHOT" apply false
java
}
architectury {
minecraft = property("minecraft_version").toString()
}
allprojects {
group = property("maven_group").toString()
version = property("mod_version").toString()
}
val javaRelease: Int = (rootProject.findProperty("java_release") as? String)?.toIntOrNull() ?: 21
val javaVersion: JavaVersion = JavaVersion.toVersion(javaRelease.toString())
subprojects {
apply(plugin = "java")
java {
sourceCompatibility = javaVersion
targetCompatibility = javaVersion
}
tasks.withType<JavaCompile> {
options.encoding = "UTF-8"
options.release.set(javaRelease)
}
if (name == "helper" || name == "common") {
repositories { mavenCentral() }
return@subprojects
}
apply(plugin = "architectury-plugin")
repositories {
mavenCentral()
maven("https://maven.architectury.dev/")
maven("https://maven.fabricmc.net/")
maven("https://maven.minecraftforge.net/")
maven("https://maven.neoforged.net/releases/")
}
}
tasks.register("buildAll") {
dependsOn(":fabric:build", ":forge:build", ":neoforge:build")
doLast {
println("=== OpenFriend mod loaders built ===")
}
}