Skip to content

Commit 4cecff9

Browse files
committed
Adjust Maven property file to use the same variable names as the official distribution.
1 parent 7d42756 commit 4cecff9

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

.mvn/wrapper/maven-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,5 @@
1616
# under the License.
1717
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.9/apache-maven-3.9.9-bin.zip
1818
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.3.2/maven-wrapper-3.3.2.jar
19-
wrapperHash=3d8f20ce6103913be8b52aef6d994e0c54705fb527324ceb9b835b338739c7a8
19+
wrapperSha256Sum=3d8f20ce6103913be8b52aef6d994e0c54705fb527324ceb9b835b338739c7a8
2020
distributionSha256Sum=4ec3f26fb1a692473aea0235c300bd20f0f9fe741947c82c1234cefd76ac3a3c

mvnw

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -269,13 +269,13 @@ else
269269
fi
270270

271271
# Validate the Maven wrapper's hash (Byte Buddy edit)
272-
wrapperHash=""
272+
wrapperSha256Sum=""
273273
while IFS="=" read key value; do
274-
case "$key" in (wrapperHash) wrapperHash=$value; break ;;
274+
case "$key" in (wrapperSha256Sum) wrapperSha256Sum=$value; break ;;
275275
esac
276276
done < "$BASE_DIR/.mvn/$wrapperLocation/maven-wrapper.properties"
277-
if [ -n "$wrapperHash" ]; then
278-
if ! echo "$wrapperHash $BASE_DIR/.mvn/$wrapperLocation/maven-wrapper.jar" | shasum -a 256 -c > /dev/null; then
277+
if [ -n "$wrapperSha256Sum" ]; then
278+
if ! echo "$wrapperSha256Sum $BASE_DIR/.mvn/$wrapperLocation/maven-wrapper.jar" | shasum -a 256 -c > /dev/null; then
279279
echo "Could not validate hash of maven-wrapper.jar";
280280
exit 1
281281
fi

mvnw.cmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ if exist %WRAPPER_JAR% (
170170
@REM Validate the Maven wrapper's hash (Byte Buddy edit)
171171
SET FILE_HASH=""
172172
FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\%WRAPPER_LOCATION%\maven-wrapper.properties") DO (
173-
IF "%%A"=="wrapperHash" SET FILE_HASH=%%B
173+
IF "%%A"=="wrapperSha256Sum" SET FILE_HASH=%%B
174174
)
175175
IF NOT %FILE_HASH%=="" (
176176
powershell -Command "&{"^

0 commit comments

Comments
 (0)