Skip to content

Commit

Permalink
Merge pull request #503 from grails/exclude-org.graalvm-dependencies
Browse files Browse the repository at this point in the history
exclude org.graalvm dependencies from the deployable war/jar
  • Loading branch information
jamesfredley authored Jan 29, 2025
2 parents 493f64d + ede2087 commit 16f50d8
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,18 @@ repositories {

@dependencies.template(applicationType, project, features, gradleBuild)

@if(features.contains("asset-pipeline-grails")) {
// exclude org.graalvm dependencies which are required by asset-pipeline-core
// for bootRun but are not required in the deployed war/jar
// see: https://github.com/grails/grails-core/pull/13971
tasks.named { it in ['bootWar', 'bootJar', 'war'] }.configureEach {
classpath = classpath.findAll {
!it.toString().contains('org.graalvm.')
}
}

}

@if(features.contains("geb-with-webdriver-binaries")) {
// geb-with-webdriver-binaries is limited to Gradle 8.6 with max JDK 21
compileJava.options.release = @JdkVersion.valueOf(Math.min(features.javaVersion().majorVersion(), JdkVersion.JDK_21.majorVersion())).majorVersion()
Expand Down

0 comments on commit 16f50d8

Please sign in to comment.