Skip to content

Commit f27fba7

Browse files
committed
feat: fabric 1.21 support
1 parent e0f7606 commit f27fba7

3 files changed

Lines changed: 44 additions & 0 deletions

File tree

fabric/1.21/build.gradle.kts

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
import org.gradle.kotlin.dsl.withType
2+
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
3+
4+
dependencies {
5+
implementation(project(":fabric:1.20.4"))!!
6+
}
7+
8+
sourceSets {
9+
main {
10+
java {
11+
srcDir(project(":fabric:1.20.4").sourceSets.main.get().java)
12+
}
13+
kotlin {
14+
srcDir(project(":fabric:1.20.4").sourceSets.main.get().kotlin)
15+
}
16+
resources {
17+
srcDir(project(":fabric:1.20.4").sourceSets.main.get().resources)
18+
}
19+
}
20+
}
21+
22+
tasks.withType<KotlinCompile> {
23+
kotlinOptions {
24+
jvmTarget = "21"
25+
freeCompilerArgs = listOf("-Xjvm-default=all")
26+
}
27+
}
28+
29+
tasks.withType<JavaCompile>().configureEach {
30+
options.release.set(21)
31+
}
32+
33+
java {
34+
withSourcesJar()
35+
36+
sourceCompatibility = JavaVersion.VERSION_21
37+
targetCompatibility = JavaVersion.VERSION_21
38+
}

fabric/1.21/gradle.properties

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
minecraft_version=1.21
2+
yarn_mappings=1.21+build.9
3+
fabric_version=0.102.0+1.21
4+
adventure_version=5.14.1

settings.gradle.kts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,3 +36,5 @@ include("fabric:1.21.8")
3636
findProject(":fabric:1.21.8")?.name = "1.21.8"
3737
include("fabric:1.21.5")
3838
findProject(":fabric:1.21.5")?.name = "1.21.5"
39+
include("fabric:1.21")
40+
findProject(":fabric:1.21")?.name = "1.21"

0 commit comments

Comments
 (0)