Skip to content

Commit 5ce0419

Browse files
iluwatarohbus
andauthored
task: Update Maven version (#1949)
* Update maven and maven wrapper to the latest versions * Update maven-war-plugin version Co-authored-by: Subhrodip Mohanta <[email protected]>
1 parent 58ce3a2 commit 5ce0419

File tree

5 files changed

+66
-65
lines changed

5 files changed

+66
-65
lines changed

.mvn/wrapper/maven-wrapper.properties

+18-25
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,18 @@
1-
#
2-
# The MIT License
3-
# Copyright © 2014-2021 Ilkka Seppälä
4-
#
5-
# Permission is hereby granted, free of charge, to any person obtaining a copy
6-
# of this software and associated documentation files (the "Software"), to deal
7-
# in the Software without restriction, including without limitation the rights
8-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9-
# copies of the Software, and to permit persons to whom the Software is
10-
# furnished to do so, subject to the following conditions:
11-
#
12-
# The above copyright notice and this permission notice shall be included in
13-
# all copies or substantial portions of the Software.
14-
#
15-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21-
# THE SOFTWARE.
22-
#
23-
24-
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.6.3/apache-maven-3.6.3-bin.zip
25-
wrapperUrl=https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.4/apache-maven-3.8.4-bin.zip
18+
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar

model-view-viewmodel/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
<zk.version>9.0.0</zk.version>
4242
<guava.version>19.0</guava.version>
4343
<jetty-maven-plugin.version>9.4.28.v20200408</jetty-maven-plugin.version>
44-
<maven-war-plugin.version>2.1.1</maven-war-plugin.version>
44+
<maven-war-plugin.version>3.3.2</maven-war-plugin.version>
4545
<maven-assembly-plugin.version>2.2</maven-assembly-plugin.version>
4646
<maven.build.timestamp.format>yyyy-MM-dd</maven.build.timestamp.format>
4747
<packname>-${project.version}-FL-${maven.build.timestamp}</packname>

mvnw

+12-6
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,10 @@
3636

3737
if [ -z "$MAVEN_SKIP_RC" ] ; then
3838

39+
if [ -f /usr/local/etc/mavenrc ] ; then
40+
. /usr/local/etc/mavenrc
41+
fi
42+
3943
if [ -f /etc/mavenrc ] ; then
4044
. /etc/mavenrc
4145
fi
@@ -145,7 +149,7 @@ if [ -z "$JAVACMD" ] ; then
145149
JAVACMD="$JAVA_HOME/bin/java"
146150
fi
147151
else
148-
JAVACMD="`which java`"
152+
JAVACMD="`\\unset -f command; \\command -v java`"
149153
fi
150154
fi
151155

@@ -212,9 +216,9 @@ else
212216
echo "Couldn't find .mvn/wrapper/maven-wrapper.jar, downloading it ..."
213217
fi
214218
if [ -n "$MVNW_REPOURL" ]; then
215-
jarUrl="$MVNW_REPOURL/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar"
219+
jarUrl="$MVNW_REPOURL/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar"
216220
else
217-
jarUrl="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar"
221+
jarUrl="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar"
218222
fi
219223
while IFS="=" read key value; do
220224
case "$key" in (wrapperUrl) jarUrl="$value"; break ;;
@@ -233,9 +237,9 @@ else
233237
echo "Found wget ... using wget"
234238
fi
235239
if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
236-
wget "$jarUrl" -O "$wrapperJarPath"
240+
wget "$jarUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath"
237241
else
238-
wget --http-user=$MVNW_USERNAME --http-password=$MVNW_PASSWORD "$jarUrl" -O "$wrapperJarPath"
242+
wget --http-user=$MVNW_USERNAME --http-password=$MVNW_PASSWORD "$jarUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath"
239243
fi
240244
elif command -v curl > /dev/null; then
241245
if [ "$MVNW_VERBOSE" = true ]; then
@@ -305,6 +309,8 @@ WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
305309

306310
exec "$JAVACMD" \
307311
$MAVEN_OPTS \
312+
$MAVEN_DEBUG_OPTS \
308313
-classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \
309-
"-Dmaven.home=${M2_HOME}" "-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \
314+
"-Dmaven.home=${M2_HOME}" \
315+
"-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \
310316
${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@"

mvnw.cmd

+34-32
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,21 @@
1+
@REM ----------------------------------------------------------------------------
2+
@REM Licensed to the Apache Software Foundation (ASF) under one
3+
@REM or more contributor license agreements. See the NOTICE file
4+
@REM distributed with this work for additional information
5+
@REM regarding copyright ownership. The ASF licenses this file
6+
@REM to you under the Apache License, Version 2.0 (the
7+
@REM "License"); you may not use this file except in compliance
8+
@REM with the License. You may obtain a copy of the License at
19
@REM
2-
@REM The MIT License
3-
@REM Copyright © 2014-2021 Ilkka Seppälä
4-
@REM
5-
@REM Permission is hereby granted, free of charge, to any person obtaining a copy
6-
@REM of this software and associated documentation files (the "Software"), to deal
7-
@REM in the Software without restriction, including without limitation the rights
8-
@REM to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9-
@REM copies of the Software, and to permit persons to whom the Software is
10-
@REM furnished to do so, subject to the following conditions:
11-
@REM
12-
@REM The above copyright notice and this permission notice shall be included in
13-
@REM all copies or substantial portions of the Software.
14-
@REM
15-
@REM THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16-
@REM IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17-
@REM FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18-
@REM AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19-
@REM LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20-
@REM OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21-
@REM THE SOFTWARE.
10+
@REM http://www.apache.org/licenses/LICENSE-2.0
2211
@REM
12+
@REM Unless required by applicable law or agreed to in writing,
13+
@REM software distributed under the License is distributed on an
14+
@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15+
@REM KIND, either express or implied. See the License for the
16+
@REM specific language governing permissions and limitations
17+
@REM under the License.
18+
@REM ----------------------------------------------------------------------------
2319

2420
@REM ----------------------------------------------------------------------------
2521
@REM Maven Start Up Batch script
@@ -50,8 +46,8 @@ if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%")
5046
@REM Execute a user defined script before this one
5147
if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre
5248
@REM check for pre script, once with legacy .bat ending and once with .cmd ending
53-
if exist "%HOME%\mavenrc_pre.bat" call "%HOME%\mavenrc_pre.bat"
54-
if exist "%HOME%\mavenrc_pre.cmd" call "%HOME%\mavenrc_pre.cmd"
49+
if exist "%USERPROFILE%\mavenrc_pre.bat" call "%USERPROFILE%\mavenrc_pre.bat" %*
50+
if exist "%USERPROFILE%\mavenrc_pre.cmd" call "%USERPROFILE%\mavenrc_pre.cmd" %*
5551
:skipRcPre
5652

5753
@setlocal
@@ -124,9 +120,9 @@ SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe"
124120
set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar"
125121
set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
126122

127-
set DOWNLOAD_URL="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar"
123+
set DOWNLOAD_URL="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar"
128124

129-
FOR /F "tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO (
125+
FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO (
130126
IF "%%A"=="wrapperUrl" SET DOWNLOAD_URL=%%B
131127
)
132128

@@ -138,7 +134,7 @@ if exist %WRAPPER_JAR% (
138134
)
139135
) else (
140136
if not "%MVNW_REPOURL%" == "" (
141-
SET DOWNLOAD_URL="%MVNW_REPOURL%/io/takari/maven-wrapper/0.5.6/maven-wrapper-0.5.6.jar"
137+
SET DOWNLOAD_URL="%MVNW_REPOURL%/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar"
142138
)
143139
if "%MVNW_VERBOSE%" == "true" (
144140
echo Couldn't find %WRAPPER_JAR%, downloading it ...
@@ -162,7 +158,13 @@ if exist %WRAPPER_JAR% (
162158
@REM work with both Windows and non-Windows executions.
163159
set MAVEN_CMD_LINE_ARGS=%*
164160

165-
%MAVEN_JAVA_EXE% %JVM_CONFIG_MAVEN_PROPS% %MAVEN_OPTS% %MAVEN_DEBUG_OPTS% -classpath %WRAPPER_JAR% "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %*
161+
%MAVEN_JAVA_EXE% ^
162+
%JVM_CONFIG_MAVEN_PROPS% ^
163+
%MAVEN_OPTS% ^
164+
%MAVEN_DEBUG_OPTS% ^
165+
-classpath %WRAPPER_JAR% ^
166+
"-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" ^
167+
%WRAPPER_LAUNCHER% %MAVEN_CONFIG% %*
166168
if ERRORLEVEL 1 goto error
167169
goto end
168170

@@ -172,15 +174,15 @@ set ERROR_CODE=1
172174
:end
173175
@endlocal & set ERROR_CODE=%ERROR_CODE%
174176

175-
if not "%MAVEN_SKIP_RC%" == "" goto skipRcPost
177+
if not "%MAVEN_SKIP_RC%"=="" goto skipRcPost
176178
@REM check for post script, once with legacy .bat ending and once with .cmd ending
177-
if exist "%HOME%\mavenrc_post.bat" call "%HOME%\mavenrc_post.bat"
178-
if exist "%HOME%\mavenrc_post.cmd" call "%HOME%\mavenrc_post.cmd"
179+
if exist "%USERPROFILE%\mavenrc_post.bat" call "%USERPROFILE%\mavenrc_post.bat"
180+
if exist "%USERPROFILE%\mavenrc_post.cmd" call "%USERPROFILE%\mavenrc_post.cmd"
179181
:skipRcPost
180182

181183
@REM pause the script if MAVEN_BATCH_PAUSE is set to 'on'
182-
if "%MAVEN_BATCH_PAUSE%" == "on" pause
184+
if "%MAVEN_BATCH_PAUSE%"=="on" pause
183185

184-
if "%MAVEN_TERMINATE_CMD%" == "on" exit %ERROR_CODE%
186+
if "%MAVEN_TERMINATE_CMD%"=="on" exit %ERROR_CODE%
185187

186-
exit /B %ERROR_CODE%
188+
cmd /C exit /B %ERROR_CODE%

naked-objects/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@
150150
</plugin>
151151
<plugin>
152152
<artifactId>maven-war-plugin</artifactId>
153-
<version>2.4</version>
153+
<version>3.3.2</version>
154154
</plugin>
155155
<plugin>
156156
<groupId>org.mortbay.jetty</groupId>

0 commit comments

Comments
 (0)