modern-java-practices
modern-java-practices copied to clipboard
Gradle equivalent of Maven enforcer for build tool versioning
The Gradle build is missing the equivalent of Maven's "enforcer" plugin to ensure that the build runs on the right version of Gradle.
This means updating gradle.properties, settings.gradle, and build.gradle.
This gap was come across while reviewing the static analysis page.
Note that this was recently marked as unblocked: see https://github.com/kordamp/enforcer-gradle-plugin/issues/17#issuecomment-2265501400.
Acceptance criteria
- Using the
gradlewscript continues working (typically it uses the most recent Gradle version) - Using older Gradle versions either pass or fail depending on the enforcer rules for version of Gradle
References
- https://kordamp.org/enforcer-gradle-plugin/
Updated issue for Gradle Enforcer: https://github.com/kordamp/enforcer-gradle-plugin/issues/17#issuecomment-2265301080.