Skip to content
This repository was archived by the owner on Feb 27, 2025. It is now read-only.

Commit 0c3cb09

Browse files
committed
Use Java 21
1 parent 97e1f6b commit 0c3cb09

File tree

2 files changed

+10
-7
lines changed

2 files changed

+10
-7
lines changed

commandapi-documentation-code/build.gradle.kts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import org.jetbrains.kotlin.config.JvmTarget
1+
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
22
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
33

44
/*
@@ -8,7 +8,7 @@ import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
88
plugins {
99
`java-library`
1010
`maven-publish`
11-
kotlin("jvm") version "1.9.0"
11+
kotlin("jvm") version "2.1.0"
1212
}
1313

1414
repositories {
@@ -51,7 +51,8 @@ dependencies {
5151
group = "dev.jorel"
5252
version = "9.6.2-SNAPSHOT"
5353
description = "commandapi-documentation-code"
54-
java.sourceCompatibility = JavaVersion.VERSION_16
54+
java.sourceCompatibility = JavaVersion.VERSION_21
55+
java.targetCompatibility = JavaVersion.VERSION_21
5556

5657
java {
5758
withSourcesJar()
@@ -63,7 +64,7 @@ tasks.withType<JavaCompile>() {
6364
}
6465

6566
tasks.withType<KotlinCompile> {
66-
kotlinOptions.jvmTarget = "16"
67+
compilerOptions.jvmTarget = JvmTarget.JVM_21
6768
}
6869

6970
tasks.withType<Javadoc>() {

commandapi-documentation-velocity-code/build.gradle.kts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
12
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
23

34
/*
@@ -7,7 +8,7 @@ import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
78
plugins {
89
`java-library`
910
`maven-publish`
10-
kotlin("jvm") version "1.9.0"
11+
kotlin("jvm") version "2.1.0"
1112
}
1213

1314
repositories {
@@ -40,7 +41,8 @@ dependencies {
4041
group = "dev.jorel"
4142
version = "9.6.2-SNAPSHOT"
4243
description = "commandapi-documentation-velocity-code"
43-
java.sourceCompatibility = JavaVersion.VERSION_16
44+
java.sourceCompatibility = JavaVersion.VERSION_21
45+
java.targetCompatibility = JavaVersion.VERSION_21
4446

4547
java {
4648
withSourcesJar()
@@ -52,7 +54,7 @@ tasks.withType<JavaCompile>() {
5254
}
5355

5456
tasks.withType<KotlinCompile> {
55-
kotlinOptions.jvmTarget = "16"
57+
compilerOptions.jvmTarget = JvmTarget.JVM_21
5658
}
5759

5860
tasks.withType<Javadoc>() {

0 commit comments

Comments
 (0)