Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@ ext {
}

groovyDependencies = [
[group: groovyGroup, name: "groovy", version: groovyVersion]
dependencyFactory.create(groovyGroup, "groovy", groovyVersion)
]
groovyConsoleExtraDependencies = [
[group: groovyGroup, name: "groovy-console", version: groovyVersion],
[group: groovyGroup, name: "groovy-test-junit5", version: groovyVersion], // for executing specs
[group: "org.apache.ivy", name: "ivy", version: "2.5.3"] // for @Grab support
dependencyFactory.create(groovyGroup, "groovy-console", groovyVersion),
dependencyFactory.create(groovyGroup, "groovy-test-junit5", groovyVersion), // for executing specs
dependencyFactory.create("org.apache.ivy", "ivy", "2.5.3"), // For @Grab support
]
maxGroovyVersion = snapshotVersion ? "9.9.99" : maxGroovyVersion
if (System.getProperty("groovyVersion")) {
Expand Down
16 changes: 7 additions & 9 deletions gradle/publishMaven.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,13 @@ ext {
publishing {
publications {
maven(MavenPublication) {
afterEvaluate {
pom.packaging = project.ext.packaging
if (project.ext.packaging == "pom") {
from(components.javaPlatform)
} else {
from(components.java)
artifact(sourcesJar)
artifact(javadocJar)
}
pluginManager.withPlugin("java-library") {
from(components.java)
artifact(sourcesJar)
artifact(javadocJar)
}
pluginManager.withPlugin("java-platform") {
from(components.javaPlatform)
}
pom {
name = provider { project.ext.displayName }
Expand Down
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionSha256Sum=bd71102213493060956ec229d946beee57158dbd89d0e62b91bca0fa2c5f3531
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
distributionSha256Sum=a17ddd85a26b6a7f5ddb71ff8b05fc5104c0202c6e64782429790c933686c806
distributionUrl=https\://services.gradle.org/distributions/gradle-9.1.0-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
5 changes: 1 addition & 4 deletions gradlew
Original file line number Diff line number Diff line change
@@ -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.
Expand Down Expand Up @@ -114,7 +114,6 @@ case "$( uname )" in #(
NONSTOP* ) nonstop=true ;;
esac

CLASSPATH="\\\"\\\""


# Determine the Java command to use to start the JVM.
Expand Down Expand Up @@ -172,7 +171,6 @@ fi
# For Cygwin or MSYS, switch paths to Windows format before running java
if "$cygwin" || "$msys" ; then
APP_HOME=$( cygpath --path --mixed "$APP_HOME" )
CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )

JAVACMD=$( cygpath --unix "$JAVACMD" )

Expand Down Expand Up @@ -212,7 +210,6 @@ DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'

set -- \
"-Dorg.gradle.appname=$APP_BASE_NAME" \
-classpath "$CLASSPATH" \
-jar "$APP_HOME/gradle/wrapper/gradle-wrapper.jar" \
"$@"

Expand Down
3 changes: 1 addition & 2 deletions gradlew.bat
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,10 @@ goto fail
:execute
@rem Setup the command line

set CLASSPATH=


@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %*
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %*

:end
@rem End local scope for the variables with windows NT shell
Expand Down
5 changes: 3 additions & 2 deletions spock-core/core.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,14 @@ dependencies {


tasks.named("jar", Jar) {
def projName = project.name
manifest {
attributes(
'Build-Revision': versioning.info.commit,
'Specification-Title': project.name,
'Specification-Title': projName,
'Specification-Version': baseVersion,
'Specification-Vendor': 'spockframework.org',
'Implementation-Title': project.name,
'Implementation-Title': projName,
'Implementation-Version': variantLessVersion,
'Implementation-Vendor': 'spockframework.org',
'Automatic-Module-Name': 'org.spockframework.core'
Expand Down
16 changes: 14 additions & 2 deletions spock-spring/boot2-test/boot2-test.gradle
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import org.springframework.boot.gradle.plugin.SpringBootPlugin

/*
* Copyright 2018 the original author or authors.
*
Expand All @@ -15,8 +17,18 @@
*/

plugins {
id "io.spring.dependency-management" version "1.0.5.RELEASE"
id 'org.springframework.boot' version "2.5.3"
// Normally, the Spring Boot 2 Gradle Plugin would not be compatible with Gradle 9+
// To get around this issue, we use the dependency-management plugin in isolation
// as described here: https://docs.spring.io/spring-boot/docs/2.7.7/gradle-plugin/reference/htmlsingle/#managing-dependencies.dependency-management-plugin.using-in-isolation
// This way, we get proper test execution and realistic version resolution on Gradle 9
id 'org.springframework.boot' version "2.7.18" apply false
id "io.spring.dependency-management" version "1.1.7"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about instead removing the plugin from both places?
It is a relict from times when Gradle did not have built-in BOM support, by now does more harm than good, and even its maintainer recommends not to use it anymore, but instead the built-in BOM support using platform(...).
@leonard84 what do you think?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I initially wanted this PR to be as non-invasive as possible which is why I opted for this variant.

I agree however that the bom variant would be much simpler.

}

dependencyManagement {
imports {
mavenBom SpringBootPlugin.BOM_COORDINATES
}
}

// Spring dependency management downgrades the jupiter version to 5.7.2 otherwise
Expand Down
4 changes: 2 additions & 2 deletions spock-spring/boot3-test/boot3-test.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
* limitations under the License.
*/
plugins {
id 'org.springframework.boot' version '3.0.0'
id 'io.spring.dependency-management' version '1.1.0'
id 'org.springframework.boot' version '3.5.5'
id 'io.spring.dependency-management' version '1.1.7'
id 'groovy'
}

Expand Down
Loading