diff --git a/docs/changes/README.md b/docs/changes/README.md index d5e5890f9..563668fe1 100644 --- a/docs/changes/README.md +++ b/docs/changes/README.md @@ -3,6 +3,9 @@ ## [Unreleased](https://github.com/GradleUp/shadow/compare/9.0.0-beta16...HEAD) - 2025-xx-xx +**Fixed** + +- Fix compatibility for Gradle 9.0.0 RC1. ([#1468](https://github.com/GradleUp/shadow/pull/1468)) ## [9.0.0-beta16](https://github.com/GradleUp/shadow/releases/tag/9.0.0-beta16) - 2025-06-14 diff --git a/gradle/lint-baseline.xml b/gradle/lint-baseline.xml index f491065a3..9ed89eb90 100644 --- a/gradle/lint-baseline.xml +++ b/gradle/lint-baseline.xml @@ -1,5 +1,5 @@ - + @@ -162,7 +162,7 @@ errorLine2="~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"> @@ -173,7 +173,7 @@ errorLine2=" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"> @@ -184,7 +184,7 @@ errorLine2=" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"> diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar index 1b33c55ba..8bdaf60c7 100644 Binary files a/gradle/wrapper/gradle-wrapper.jar and b/gradle/wrapper/gradle-wrapper.jar differ diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index ff23a68d7..407c905d9 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.2-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-9.0.0-rc-1-bin.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/gradlew b/gradlew index 23d15a936..ef07e0162 100755 --- a/gradlew +++ b/gradlew @@ -1,7 +1,7 @@ #!/bin/sh # -# Copyright © 2015-2021 the original authors. +# Copyright © 2015 the original authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/src/main/kotlin/com/github/jengelman/gradle/plugins/shadow/internal/GradleCompat.kt b/src/main/kotlin/com/github/jengelman/gradle/plugins/shadow/internal/GradleCompat.kt index e7e7299b8..c77a97790 100644 --- a/src/main/kotlin/com/github/jengelman/gradle/plugins/shadow/internal/GradleCompat.kt +++ b/src/main/kotlin/com/github/jengelman/gradle/plugins/shadow/internal/GradleCompat.kt @@ -104,7 +104,6 @@ internal fun ProjectDependency.dependencyProjectCompat(project: Project): Projec return if (GradleVersion.current() >= GradleVersion.version("8.11")) { project.project(path) } else { - @Suppress("DEPRECATION") - dependencyProject + return this::class.java.getDeclaredMethod("getDependencyProject").invoke(this) as Project } } diff --git a/src/main/kotlin/com/github/jengelman/gradle/plugins/shadow/tasks/ShadowJar.kt b/src/main/kotlin/com/github/jengelman/gradle/plugins/shadow/tasks/ShadowJar.kt index dd00a5c41..f4be0c5dd 100644 --- a/src/main/kotlin/com/github/jengelman/gradle/plugins/shadow/tasks/ShadowJar.kt +++ b/src/main/kotlin/com/github/jengelman/gradle/plugins/shadow/tasks/ShadowJar.kt @@ -27,7 +27,6 @@ import kotlin.reflect.full.hasAnnotation import org.apache.tools.zip.Zip64Mode import org.apache.tools.zip.ZipOutputStream import org.gradle.api.Action -import org.gradle.api.UncheckedIOException import org.gradle.api.artifacts.Configuration import org.gradle.api.file.ArchiveOperations import org.gradle.api.file.ConfigurableFileCollection @@ -330,7 +329,7 @@ public abstract class ShadowJar : setMethod(entryCompressionMethod) } } catch (e: Exception) { - throw UncheckedIOException("Unable to create ZIP output stream for file $destination.", e) + throw IOException("Unable to create ZIP output stream for file $destination.", e) } } val unusedClasses = if (minimizeJar.get()) {