Skip to content
This repository was archived by the owner on Nov 22, 2024. It is now read-only.

Commit 8b2e1cc

Browse files
Pranav-yadavfacebook-github-bot
authored andcommitted
Upgrade to Gradle 8.1.1 (#4907)
Summary: Upgrade to Gradle `8.1.1` Done using: ```bash ./gradlew wrapper --gradle-version=8.1.1 --distribution-type=all ``` This is to align with the bump to gradle `8.x` in React Native. ## Changelog [GENERAL] [SECURITY] - Upgrade to Gradle `8.1.1` Pull Request resolved: #4907 Test Plan: - CI checks should pass & builds should be successful without any errors. Reviewed By: antonk52 Differential Revision: D47553708 Pulled By: passy fbshipit-source-id: a0ab9ab732a254c563d8cb55b277f73571da8927
1 parent 2427ba7 commit 8b2e1cc

File tree

4 files changed

+29
-14
lines changed

4 files changed

+29
-14
lines changed

gradle/wrapper/gradle-wrapper.jar

2.2 KB
Binary file not shown.

gradle/wrapper/gradle-wrapper.properties

+2-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55

66
distributionBase=GRADLE_USER_HOME
77
distributionPath=wrapper/dists
8-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1-bin.zip
8+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-all.zip
9+
networkTimeout=10000
910
zipStoreBase=GRADLE_USER_HOME
1011
zipStorePath=wrapper/dists

gradlew

+18-7
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
# Darwin, MinGW, and NonStop.
5656
#
5757
# (3) This script is generated from the Groovy template
58-
# https://github.com/gradle/gradle/blob/master/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
58+
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
5959
# within the Gradle project.
6060
#
6161
# You can find Gradle at https://github.com/gradle/gradle/.
@@ -80,13 +80,10 @@ do
8080
esac
8181
done
8282

83-
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
84-
85-
APP_NAME="Gradle"
83+
# This is normally unused
84+
# shellcheck disable=SC2034
8685
APP_BASE_NAME=${0##*/}
87-
88-
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
89-
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
86+
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
9087

9188
# Use the maximum available, or set MAX_FD != -1 to use that value.
9289
MAX_FD=maximum
@@ -143,12 +140,16 @@ fi
143140
if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
144141
case $MAX_FD in #(
145142
max*)
143+
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
144+
# shellcheck disable=SC3045
146145
MAX_FD=$( ulimit -H -n ) ||
147146
warn "Could not query maximum file descriptor limit"
148147
esac
149148
case $MAX_FD in #(
150149
'' | soft) :;; #(
151150
*)
151+
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
152+
# shellcheck disable=SC3045
152153
ulimit -n "$MAX_FD" ||
153154
warn "Could not set maximum file descriptor limit to $MAX_FD"
154155
esac
@@ -193,6 +194,10 @@ if "$cygwin" || "$msys" ; then
193194
done
194195
fi
195196

197+
198+
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
199+
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
200+
196201
# Collect all arguments for the java command;
197202
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
198203
# shell script including quotes and variable substitutions, so put them in
@@ -205,6 +210,12 @@ set -- \
205210
org.gradle.wrapper.GradleWrapperMain \
206211
"$@"
207212

213+
# Stop when "xargs" is not available.
214+
if ! command -v xargs >/dev/null 2>&1
215+
then
216+
die "xargs is not available"
217+
fi
218+
208219
# Use "xargs" to parse quoted args.
209220
#
210221
# With -n1 it outputs one arg per line, with the quotes and backslashes removed.

gradlew.bat

+9-6
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
@rem limitations under the License.
2020
@rem
2121

22-
@if "%DEBUG%" == "" @echo off
22+
@if "%DEBUG%"=="" @echo off
2323
@rem ##########################################################################
2424
@rem
2525
@rem Gradle startup script for Windows
@@ -30,7 +30,8 @@
3030
if "%OS%"=="Windows_NT" setlocal
3131

3232
set DIRNAME=%~dp0
33-
if "%DIRNAME%" == "" set DIRNAME=.
33+
if "%DIRNAME%"=="" set DIRNAME=.
34+
@rem This is normally unused
3435
set APP_BASE_NAME=%~n0
3536
set APP_HOME=%DIRNAME%
3637

@@ -45,7 +46,7 @@ if defined JAVA_HOME goto findJavaFromJavaHome
4546

4647
set JAVA_EXE=java.exe
4748
%JAVA_EXE% -version >NUL 2>&1
48-
if "%ERRORLEVEL%" == "0" goto execute
49+
if %ERRORLEVEL% equ 0 goto execute
4950

5051
echo.
5152
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
@@ -80,13 +81,15 @@ set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
8081

8182
:end
8283
@rem End local scope for the variables with windows NT shell
83-
if "%ERRORLEVEL%"=="0" goto mainEnd
84+
if %ERRORLEVEL% equ 0 goto mainEnd
8485

8586
:fail
8687
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
8788
rem the _cmd.exe /c_ return code!
88-
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
89-
exit /b 1
89+
set EXIT_CODE=%ERRORLEVEL%
90+
if %EXIT_CODE% equ 0 set EXIT_CODE=1
91+
if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE%
92+
exit /b %EXIT_CODE%
9093

9194
:mainEnd
9295
if "%OS%"=="Windows_NT" endlocal

0 commit comments

Comments
 (0)