From 0e761ca2b4d863cc905fcacfc66b1d844ffbc266 Mon Sep 17 00:00:00 2001 From: daz Date: Wed, 8 Nov 2023 20:42:41 -0800 Subject: [PATCH] Bump to Gradle 8.4 for tests and samples --- .../gradle/wrapper/gradle-wrapper.properties | 4 ++-- .github/workflow-samples/gradle-plugin/gradlew | 14 +++++++------- .../gradle/wrapper/gradle-wrapper.properties | 4 ++-- .github/workflow-samples/groovy-dsl/gradlew | 14 +++++++------- .../gradle/wrapper/gradle-wrapper.properties | 4 ++-- .github/workflow-samples/java-toolchain/gradlew | 14 +++++++------- .../gradle/wrapper/gradle-wrapper.properties | 4 ++-- .github/workflow-samples/kotlin-dsl/gradlew | 14 +++++++------- .github/workflows/ci-quick-check.yml | 2 +- .tool-versions | 2 +- .../gradlebuildaction/BaseInitScriptTest.groovy | 2 +- test/jest/cache-cleanup.test.ts | 2 +- 12 files changed, 40 insertions(+), 40 deletions(-) diff --git a/.github/workflow-samples/gradle-plugin/gradle/wrapper/gradle-wrapper.properties b/.github/workflow-samples/gradle-plugin/gradle/wrapper/gradle-wrapper.properties index 864d6c4..46671ac 100644 --- a/.github/workflow-samples/gradle-plugin/gradle/wrapper/gradle-wrapper.properties +++ b/.github/workflow-samples/gradle-plugin/gradle/wrapper/gradle-wrapper.properties @@ -1,7 +1,7 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionSha256Sum=591855b517fc635b9e04de1d05d5e76ada3f89f5fc76f87978d1b245b4f69225 -distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip +distributionSha256Sum=3e1af3ae886920c3ac87f7a91f816c0c7c436f276a6eefdb3da152100fef72ae +distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/.github/workflow-samples/gradle-plugin/gradlew b/.github/workflow-samples/gradle-plugin/gradlew index 0adc8e1..1aa94a4 100755 --- a/.github/workflow-samples/gradle-plugin/gradlew +++ b/.github/workflow-samples/gradle-plugin/gradlew @@ -145,7 +145,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then case $MAX_FD in #( max*) # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. - # shellcheck disable=SC3045 + # shellcheck disable=SC2039,SC3045 MAX_FD=$( ulimit -H -n ) || warn "Could not query maximum file descriptor limit" esac @@ -153,7 +153,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then '' | soft) :;; #( *) # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. - # shellcheck disable=SC3045 + # shellcheck disable=SC2039,SC3045 ulimit -n "$MAX_FD" || warn "Could not set maximum file descriptor limit to $MAX_FD" esac @@ -202,11 +202,11 @@ fi # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' -# Collect all arguments for the java command; -# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of -# shell script including quotes and variable substitutions, so put them in -# double quotes to make sure that they get re-expanded; and -# * put everything else in single quotes, so that it's not re-expanded. +# Collect all arguments for the java command: +# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments, +# and any embedded shellness will be escaped. +# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be +# treated as '${Hostname}' itself on the command line. set -- \ "-Dorg.gradle.appname=$APP_BASE_NAME" \ diff --git a/.github/workflow-samples/groovy-dsl/gradle/wrapper/gradle-wrapper.properties b/.github/workflow-samples/groovy-dsl/gradle/wrapper/gradle-wrapper.properties index 864d6c4..46671ac 100644 --- a/.github/workflow-samples/groovy-dsl/gradle/wrapper/gradle-wrapper.properties +++ b/.github/workflow-samples/groovy-dsl/gradle/wrapper/gradle-wrapper.properties @@ -1,7 +1,7 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionSha256Sum=591855b517fc635b9e04de1d05d5e76ada3f89f5fc76f87978d1b245b4f69225 -distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip +distributionSha256Sum=3e1af3ae886920c3ac87f7a91f816c0c7c436f276a6eefdb3da152100fef72ae +distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/.github/workflow-samples/groovy-dsl/gradlew b/.github/workflow-samples/groovy-dsl/gradlew index 0adc8e1..1aa94a4 100755 --- a/.github/workflow-samples/groovy-dsl/gradlew +++ b/.github/workflow-samples/groovy-dsl/gradlew @@ -145,7 +145,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then case $MAX_FD in #( max*) # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. - # shellcheck disable=SC3045 + # shellcheck disable=SC2039,SC3045 MAX_FD=$( ulimit -H -n ) || warn "Could not query maximum file descriptor limit" esac @@ -153,7 +153,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then '' | soft) :;; #( *) # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. - # shellcheck disable=SC3045 + # shellcheck disable=SC2039,SC3045 ulimit -n "$MAX_FD" || warn "Could not set maximum file descriptor limit to $MAX_FD" esac @@ -202,11 +202,11 @@ fi # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' -# Collect all arguments for the java command; -# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of -# shell script including quotes and variable substitutions, so put them in -# double quotes to make sure that they get re-expanded; and -# * put everything else in single quotes, so that it's not re-expanded. +# Collect all arguments for the java command: +# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments, +# and any embedded shellness will be escaped. +# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be +# treated as '${Hostname}' itself on the command line. set -- \ "-Dorg.gradle.appname=$APP_BASE_NAME" \ diff --git a/.github/workflow-samples/java-toolchain/gradle/wrapper/gradle-wrapper.properties b/.github/workflow-samples/java-toolchain/gradle/wrapper/gradle-wrapper.properties index 864d6c4..46671ac 100644 --- a/.github/workflow-samples/java-toolchain/gradle/wrapper/gradle-wrapper.properties +++ b/.github/workflow-samples/java-toolchain/gradle/wrapper/gradle-wrapper.properties @@ -1,7 +1,7 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionSha256Sum=591855b517fc635b9e04de1d05d5e76ada3f89f5fc76f87978d1b245b4f69225 -distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip +distributionSha256Sum=3e1af3ae886920c3ac87f7a91f816c0c7c436f276a6eefdb3da152100fef72ae +distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/.github/workflow-samples/java-toolchain/gradlew b/.github/workflow-samples/java-toolchain/gradlew index 0adc8e1..1aa94a4 100755 --- a/.github/workflow-samples/java-toolchain/gradlew +++ b/.github/workflow-samples/java-toolchain/gradlew @@ -145,7 +145,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then case $MAX_FD in #( max*) # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. - # shellcheck disable=SC3045 + # shellcheck disable=SC2039,SC3045 MAX_FD=$( ulimit -H -n ) || warn "Could not query maximum file descriptor limit" esac @@ -153,7 +153,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then '' | soft) :;; #( *) # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. - # shellcheck disable=SC3045 + # shellcheck disable=SC2039,SC3045 ulimit -n "$MAX_FD" || warn "Could not set maximum file descriptor limit to $MAX_FD" esac @@ -202,11 +202,11 @@ fi # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' -# Collect all arguments for the java command; -# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of -# shell script including quotes and variable substitutions, so put them in -# double quotes to make sure that they get re-expanded; and -# * put everything else in single quotes, so that it's not re-expanded. +# Collect all arguments for the java command: +# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments, +# and any embedded shellness will be escaped. +# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be +# treated as '${Hostname}' itself on the command line. set -- \ "-Dorg.gradle.appname=$APP_BASE_NAME" \ diff --git a/.github/workflow-samples/kotlin-dsl/gradle/wrapper/gradle-wrapper.properties b/.github/workflow-samples/kotlin-dsl/gradle/wrapper/gradle-wrapper.properties index 864d6c4..46671ac 100644 --- a/.github/workflow-samples/kotlin-dsl/gradle/wrapper/gradle-wrapper.properties +++ b/.github/workflow-samples/kotlin-dsl/gradle/wrapper/gradle-wrapper.properties @@ -1,7 +1,7 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionSha256Sum=591855b517fc635b9e04de1d05d5e76ada3f89f5fc76f87978d1b245b4f69225 -distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip +distributionSha256Sum=3e1af3ae886920c3ac87f7a91f816c0c7c436f276a6eefdb3da152100fef72ae +distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/.github/workflow-samples/kotlin-dsl/gradlew b/.github/workflow-samples/kotlin-dsl/gradlew index 0adc8e1..1aa94a4 100755 --- a/.github/workflow-samples/kotlin-dsl/gradlew +++ b/.github/workflow-samples/kotlin-dsl/gradlew @@ -145,7 +145,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then case $MAX_FD in #( max*) # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. - # shellcheck disable=SC3045 + # shellcheck disable=SC2039,SC3045 MAX_FD=$( ulimit -H -n ) || warn "Could not query maximum file descriptor limit" esac @@ -153,7 +153,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then '' | soft) :;; #( *) # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. - # shellcheck disable=SC3045 + # shellcheck disable=SC2039,SC3045 ulimit -n "$MAX_FD" || warn "Could not set maximum file descriptor limit to $MAX_FD" esac @@ -202,11 +202,11 @@ fi # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' -# Collect all arguments for the java command; -# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of -# shell script including quotes and variable substitutions, so put them in -# double quotes to make sure that they get re-expanded; and -# * put everything else in single quotes, so that it's not re-expanded. +# Collect all arguments for the java command: +# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments, +# and any embedded shellness will be escaped. +# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be +# treated as '${Hostname}' itself on the command line. set -- \ "-Dorg.gradle.appname=$APP_BASE_NAME" \ diff --git a/.github/workflows/ci-quick-check.yml b/.github/workflows/ci-quick-check.yml index 735ca7b..d141cfe 100644 --- a/.github/workflows/ci-quick-check.yml +++ b/.github/workflows/ci-quick-check.yml @@ -22,7 +22,7 @@ jobs: - name: Configure Gradle as default for unit test uses: ./ with: - gradle-version: 8.3 + gradle-version: 8.4 - name: Run tests run: | npm install diff --git a/.tool-versions b/.tool-versions index ba4bada..aa63c3d 100644 --- a/.tool-versions +++ b/.tool-versions @@ -1,3 +1,3 @@ # Configuration file for asdf version manager nodejs 16.18.1 -gradle 8.3 +gradle 8.4 diff --git a/test/init-scripts/src/test/groovy/com/gradle/gradlebuildaction/BaseInitScriptTest.groovy b/test/init-scripts/src/test/groovy/com/gradle/gradlebuildaction/BaseInitScriptTest.groovy index cf06a5f..eb33732 100644 --- a/test/init-scripts/src/test/groovy/com/gradle/gradlebuildaction/BaseInitScriptTest.groovy +++ b/test/init-scripts/src/test/groovy/com/gradle/gradlebuildaction/BaseInitScriptTest.groovy @@ -26,7 +26,7 @@ class BaseInitScriptTest extends Specification { static final TestGradleVersion GRADLE_6_X = new TestGradleVersion(GradleVersion.version('6.9.4'), 8, 15) static final TestGradleVersion GRADLE_7_X = new TestGradleVersion(GradleVersion.version('7.6.2'), 8, 19) static final TestGradleVersion GRADLE_8_0 = new TestGradleVersion(GradleVersion.version('8.0.2'), 8, 19) - static final TestGradleVersion GRADLE_8_X = new TestGradleVersion(GradleVersion.version('8.3'), 8, 19) + static final TestGradleVersion GRADLE_8_X = new TestGradleVersion(GradleVersion.version('8.4'), 8, 19) static final List ALL_VERSIONS = [ GRADLE_3_X, // First version where TestKit supports environment variables diff --git a/test/jest/cache-cleanup.test.ts b/test/jest/cache-cleanup.test.ts index 8b213c5..2b73206 100644 --- a/test/jest/cache-cleanup.test.ts +++ b/test/jest/cache-cleanup.test.ts @@ -49,7 +49,7 @@ test('will cleanup unused gradle versions', async () => { const gradle802 = path.resolve(gradleUserHome, "caches/8.0.2") const wrapper802 = path.resolve(gradleUserHome, "wrapper/dists/gradle-8.0.2-bin") - const gradleCurrent = path.resolve(gradleUserHome, "caches/8.3") + const gradleCurrent = path.resolve(gradleUserHome, "caches/8.4") expect(fs.existsSync(gradle802)).toBe(true) expect(fs.existsSync(wrapper802)).toBe(true)