Skip to content

Commit 6fd6f10

Browse files
committed
[mvn] Update maven wrapper to 0.5.5
1 parent f7db7f3 commit 6fd6f10

File tree

4 files changed

+30
-16
lines changed

4 files changed

+30
-16
lines changed

.mvn/wrapper/MavenWrapperDownloader.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@
2020

2121
public class MavenWrapperDownloader {
2222

23-
private static final String WRAPPER_VERSION = "0.5.3";
23+
private static final String WRAPPER_VERSION = "0.5.5";
2424
/**
2525
* Default URL to download the maven-wrapper.jar from, if no 'downloadUrl' is provided.
2626
*/
2727
private static final String DEFAULT_DOWNLOAD_URL = "https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/"
28-
+ WRAPPER_VERSION + "/maven-wrapper-" + WRAPPER_VERSION + " .jar";
28+
+ WRAPPER_VERSION + "/maven-wrapper-" + WRAPPER_VERSION + ".jar";
2929

3030
/**
3131
* Path to the maven-wrapper.properties file, which might contain a downloadUrl property to

.mvn/wrapper/maven-wrapper.properties

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
11
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.6.1/apache-maven-3.6.1-bin.zip
2-
wrapperUrl=https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.3/maven-wrapper-0.5.3.jar
3-
2+
wrapperUrl=https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.5/maven-wrapper-0.5.5.jar

mvnw

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -212,9 +212,9 @@ else
212212
echo "Couldn't find .mvn/wrapper/maven-wrapper.jar, downloading it ..."
213213
fi
214214
if [ -n "$MVNW_REPOURL" ]; then
215-
jarUrl="$MVNW_REPOURL/io/takari/maven-wrapper/0.5.3/maven-wrapper-0.5.3.jar"
215+
jarUrl="$MVNW_REPOURL/io/takari/maven-wrapper/0.5.5/maven-wrapper-0.5.5.jar"
216216
else
217-
jarUrl="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.3/maven-wrapper-0.5.3.jar"
217+
jarUrl="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.5/maven-wrapper-0.5.5.jar"
218218
fi
219219
while IFS="=" read key value; do
220220
case "$key" in (wrapperUrl) jarUrl="$value"; break ;;
@@ -296,6 +296,11 @@ if $cygwin; then
296296
MAVEN_PROJECTBASEDIR=`cygpath --path --windows "$MAVEN_PROJECTBASEDIR"`
297297
fi
298298

299+
# Provide a "standardized" way to retrieve the CLI args that will
300+
# work with both Windows and non-Windows executions.
301+
MAVEN_CMD_LINE_ARGS="$MAVEN_CONFIG $@"
302+
export MAVEN_CMD_LINE_ARGS
303+
299304
WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
300305

301306
exec "$JAVACMD" \

mvnw.cmd

Lines changed: 20 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
@echo off
3838
@REM set title of command window
3939
title %0
40-
@REM enable echoing my setting MAVEN_BATCH_ECHO to 'on'
40+
@REM enable echoing by setting MAVEN_BATCH_ECHO to 'on'
4141
@if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO%
4242

4343
@REM set %HOME% to equivalent of $HOME
@@ -120,7 +120,7 @@ SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe"
120120
set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar"
121121
set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
122122

123-
set DOWNLOAD_URL="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.3/maven-wrapper-0.5.3.jar"
123+
set DOWNLOAD_URL="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.5/maven-wrapper-0.5.5.jar"
124124

125125
FOR /F "tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO (
126126
IF "%%A"=="wrapperUrl" SET DOWNLOAD_URL=%%B
@@ -129,25 +129,35 @@ FOR /F "tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-
129129
@REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
130130
@REM This allows using the maven wrapper in projects that prohibit checking in binary data.
131131
if exist %WRAPPER_JAR% (
132-
echo Found %WRAPPER_JAR%
132+
if "%MVNW_VERBOSE%" == "true" (
133+
echo Found %WRAPPER_JAR%
134+
)
133135
) else (
134-
if not "%MVNW_REPOURL%" == "" (
135-
SET DOWNLOAD_URL="%MVNW_REPOURL%/io/takari/maven-wrapper/0.5.3/maven-wrapper-0.5.3.jar"
136-
)
137-
echo Couldn't find %WRAPPER_JAR%, downloading it ...
138-
echo Downloading from: %DOWNLOAD_URL%
139-
136+
if not "%MVNW_REPOURL%" == "" (
137+
SET DOWNLOAD_URL="%MVNW_REPOURL%/io/takari/maven-wrapper/0.5.5/maven-wrapper-0.5.5.jar"
138+
)
139+
if "%MVNW_VERBOSE%" == "true" (
140+
echo Couldn't find %WRAPPER_JAR%, downloading it ...
141+
echo Downloading from: %DOWNLOAD_URL%
142+
)
143+
140144
powershell -Command "&{"^
141145
"$webclient = new-object System.Net.WebClient;"^
142146
"if (-not ([string]::IsNullOrEmpty('%MVNW_USERNAME%') -and [string]::IsNullOrEmpty('%MVNW_PASSWORD%'))) {"^
143147
"$webclient.Credentials = new-object System.Net.NetworkCredential('%MVNW_USERNAME%', '%MVNW_PASSWORD%');"^
144148
"}"^
145149
"[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; $webclient.DownloadFile('%DOWNLOAD_URL%', '%WRAPPER_JAR%')"^
146150
"}"
147-
echo Finished downloading %WRAPPER_JAR%
151+
if "%MVNW_VERBOSE%" == "true" (
152+
echo Finished downloading %WRAPPER_JAR%
153+
)
148154
)
149155
@REM End of extension
150156

157+
@REM Provide a "standardized" way to retrieve the CLI args that will
158+
@REM work with both Windows and non-Windows executions.
159+
set MAVEN_CMD_LINE_ARGS=%*
160+
151161
%MAVEN_JAVA_EXE% %JVM_CONFIG_MAVEN_PROPS% %MAVEN_OPTS% %MAVEN_DEBUG_OPTS% -classpath %WRAPPER_JAR% "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %*
152162
if ERRORLEVEL 1 goto error
153163
goto end

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy