Skip to content

Commit ffa88d1

Browse files
committed
Upgrade Java version from 1.8 to 17 - Update build.gradle.kts to use Java 17 with JVM toolchain - Update Dokka plugin to version 1.9.10 - Remove deprecated jcenter repository - Update Gradle wrapper to version 8.5 - Update GitHub Actions to use Java 17 and latest actions versions
1 parent 6fcde24 commit ffa88d1

File tree

4 files changed

+23
-16
lines changed

4 files changed

+23
-16
lines changed

.github/workflows/check.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,13 @@ jobs:
88
runs-on: ubuntu-latest
99

1010
steps:
11-
- uses: actions/checkout@v2
12-
- name: Set up JDK 1.8
13-
uses: actions/setup-java@v1
11+
- uses: actions/checkout@v4
12+
- name: Set up JDK 17
13+
uses: actions/setup-java@v4
1414
with:
15-
java-version: 1.8
15+
java-version: '17'
16+
distribution: 'temurin'
1617
- name: Build with Gradle
17-
uses: eskatos/gradle-command-action@v1.3.3
18+
uses: gradle/gradle-build-action@v2
1819
with:
1920
arguments: build

.github/workflows/publish.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,14 @@ jobs:
88
runs-on: ubuntu-latest
99

1010
steps:
11-
- uses: actions/checkout@v2
12-
- name: Set up JDK 1.8
13-
uses: actions/setup-java@v1
11+
- uses: actions/checkout@v4
12+
- name: Set up JDK 17
13+
uses: actions/setup-java@v4
1414
with:
15-
java-version: 1.8
15+
java-version: '17'
16+
distribution: 'temurin'
1617
- name: Build with Gradle
17-
uses: eskatos/gradle-command-action@v1.3.3
18+
uses: gradle/gradle-build-action@v2
1819
with:
1920
arguments: publishToSonatype closeAndReleaseSonatypeStagingRepository
2021
env:

build.gradle.kts

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,27 @@ plugins {
33
kotlin("jvm") version embeddedKotlinVersion
44
`maven-publish`
55
signing
6-
id("org.jetbrains.dokka") version "1.4.20"
6+
id("org.jetbrains.dokka") version "1.9.10"
77
id("io.github.gradle-nexus.publish-plugin") version "1.0.0"
88
}
99

1010
group = "com.wantedly"
1111
version = "1.1.0"
1212

13+
java {
14+
toolchain {
15+
languageVersion.set(JavaLanguageVersion.of(17))
16+
}
17+
}
18+
1319
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().all {
14-
// Gradle requires targeting 1.8 or higher.
15-
kotlinOptions.jvmTarget = "1.8"
20+
kotlinOptions {
21+
jvmTarget = JavaVersion.VERSION_17.toString()
22+
}
1623
}
1724

1825
repositories {
1926
mavenCentral()
20-
// Workaround: https://github.com/Kotlin/dokka/issues/41
21-
jcenter()
2227
}
2328

2429
dependencies {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-6.6.1-all.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists

0 commit comments

Comments
 (0)