The Gradle team is excited to announce Gradle 8.2-milestone-1.
This release features 1, 2, ... n, and more.
We would like to thank the following community members for their contributions to this release of Gradle:
Switch your build to use Gradle 8.2-milestone-1 by updating your wrapper:
./gradlew wrapper --gradle-version=8.2-milestone-1
See the Gradle 7.x upgrade guide to learn about deprecations, breaking changes and other considerations when upgrading to Gradle 8.2-milestone-1.
For Java, Groovy, Kotlin and Android compatibility, see the full compatibility notes.
The version of the JaCoCo code coverage tool used by the jacoco
plugin has been upgraded to 0.8.9.
The wrapper task now validates the configured distribution url before writing it to the gradle-wrapper.properties
file. This surfaces invalid urls early and can prevent IO exceptions at execution time.
More details can be found in the dedicated section of the Gradle Wrapper user manual chapter.
Progress is now displayed during Java toolchains discovery. This can be useful during a cold-start of Gradle for users who have environments with a lot of JVM installations in them.
Gradle's Kotlin DSL provides an alternative syntax to the Groovy DSL with an enhanced editing experience in supported IDEs — superior content assistance, refactoring documentation, and more.
A versioned reference documentation for the Gradle Kotlin DSL is now published alongside the user manual. This reference covers both the Kotlin DSL and the Gradle Java API.
You can use the Kotlin DSL reference search functionality to drill through the available members.
init
defaults to the Kotlin DSLStarting with this release running gradle init
now defaults to generating new builds using the Kotlin DSL.
In interactive mode you can choose which DSL to use and the Kotlin one is now listed first:
Select build script DSL:
1: Kotlin
2: Groovy
Enter selection (default: Kotlin) [1..2]
See the build init user manual chapter for more information.
Gradle Kotlin DSL scripts are compiled by Gradle during the configuration phase of your build. Deprecation warnings found by the Kotlin compiler are reported on the console when compiling the scripts.
It is now possible to configure your build to fail on any warning emitted during script compilation by setting the org.gradle.kotlin.dsl.allWarningsAsErrors
Gradle property to true
:
# gradle.properties
org.gradle.kotlin.dsl.allWarningsAsErrors=true
More details can be found in the dedicated section of the Kotlin DSL user manual chapter.
To mitigate the security risks and avoid integrating compromised dependencies in your project, Gradle supports dependency verification.
Exported PGP keys are now stripped to contain only necessary data. This feature can significantly reduce keyring sizes.
In addition, the exported keyring is sorted by key id and de-duplicated to ensure a consistent ordering of keys, which reduces changes and conflicts when updating the keyring.
In order to benefit from these changes, users will have to generate again their keyring.
Task options of type boolean
, Boolean
, and Property<Boolean>
now generate an opposite option to facilitate setting the value to false
. For example, --no-foo
is created for the provided option --foo
.
See the task options user manual section for more information.
A series of small improvements were added to the console output when the build fails: suggestions are moved from the error message to the * Try
section, a link help.gradle.org is not shown for recoverable errors (e.g. upon compilation failure), just to name a few. The complete list of suggestions is available here. This change is a first step towards implementing the clean and actionable error reporting item in the public roadmap.
Promoted features are features that were incubating in previous versions of Gradle but are now supported and subject to backwards compatibility. See the User Manual section on the “Feature Lifecycle” for more information.
The following are the features that have been promoted in this Gradle release.
Known issues are problems that were discovered post release that are directly related to changes made in this release.
We love getting contributions from the Gradle community. For information on contributing, please see gradle.org/contribute.
If you find a problem with this release, please file a bug on GitHub Issues adhering to our issue guidelines. If you're not sure you're encountering a bug, please use the forum.
We hope you will build happiness with Gradle, and we look forward to your feedback via Twitter or on GitHub.