Skip to content

Commit

Permalink
chore: upgrade to gradle 8.5 (#1153)
Browse files Browse the repository at this point in the history
* chore: upgrade to gradle 8.5

* bump plugin version and remove suppression

* bump to 1.9.21 and fix warnings

* more fixes

* fix: use KGP from version catalog

* bump atomicfu to 0.23.1
  • Loading branch information
aajtodd authored Dec 19, 2023
1 parent 6142b87 commit 9921907
Showing 1 changed file with 17 additions and 14 deletions.
31 changes: 17 additions & 14 deletions codegen/smithy-aws-kotlin-codegen/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
/*
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0
*/
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile

/*
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0
*/
plugins {
kotlin("jvm")
alias(libs.plugins.kotlin.jvm)
jacoco
}

Expand Down Expand Up @@ -34,19 +41,15 @@ dependencies {
testImplementation(libs.kotlinx.serialization.json)
}

val jvmTargetVersion = JavaVersion.VERSION_17.toString()

tasks.compileKotlin {
kotlinOptions.jvmTarget = jvmTargetVersion
}

tasks.compileTestKotlin {
kotlinOptions.jvmTarget = jvmTargetVersion
tasks.withType<KotlinCompile> {
compilerOptions {
jvmTarget.set(JvmTarget.JVM_1_8)
}
}

tasks.withType<JavaCompile> {
sourceCompatibility = jvmTargetVersion
targetCompatibility = jvmTargetVersion
sourceCompatibility = JavaVersion.VERSION_1_8.toString()
targetCompatibility = JavaVersion.VERSION_1_8.toString()
}

// Reusable license copySpec
Expand Down Expand Up @@ -78,9 +81,9 @@ tasks.test {
// Configure jacoco (code coverage) to generate an HTML report
tasks.jacocoTestReport {
reports {
xml.isEnabled = false
csv.isEnabled = false
html.destination = file("$buildDir/reports/jacoco")
xml.required.set(false)
csv.required.set(false)
html.outputLocation.set(layout.buildDirectory.dir("reports/jacoco"))
}
}

Expand Down

0 comments on commit 9921907

Please sign in to comment.