You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by mi...@apache.org on 2021/12/20 21:42:35 UTC

[maven] branch MNG-7206 created (now 767b5b9)

This is an automated email from the ASF dual-hosted git repository.

michaelo pushed a change to branch MNG-7206
in repository https://gitbox.apache.org/repos/asf/maven.git.


      at 767b5b9  [MNG-7206] Properly prioritize JVM options from MAVEN_OPTS and jvm.config

This branch includes the following new commits:

     new 767b5b9  [MNG-7206] Properly prioritize JVM options from MAVEN_OPTS and jvm.config

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


[maven] 01/01: [MNG-7206] Properly prioritize JVM options from MAVEN_OPTS and jvm.config

Posted by mi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

michaelo pushed a commit to branch MNG-7206
in repository https://gitbox.apache.org/repos/asf/maven.git

commit 767b5b9b858b23a902f7e1436a0f9efe4712b878
Author: Michael Osipov <mi...@apache.org>
AuthorDate: Mon Dec 20 22:40:33 2021 +0100

    [MNG-7206] Properly prioritize JVM options from MAVEN_OPTS and jvm.config
    
    This closes #638
---
 apache-maven/src/assembly/shared/init     | 2 +-
 apache-maven/src/assembly/shared/init.cmd | 7 +++----
 apache-maven/src/assembly/shared/run.cmd  | 1 -
 3 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/apache-maven/src/assembly/shared/init b/apache-maven/src/assembly/shared/init
index 619bc4d..d5bd529 100755
--- a/apache-maven/src/assembly/shared/init
+++ b/apache-maven/src/assembly/shared/init
@@ -83,4 +83,4 @@ concat_lines() {
 }
 
 MAVEN_PROJECTBASEDIR="`find_maven_basedir "$@"`"
-MAVEN_OPTS="`concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config"` $MAVEN_OPTS"
+MAVEN_OPTS="$MAVEN_OPTS `concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config"`"
diff --git a/apache-maven/src/assembly/shared/init.cmd b/apache-maven/src/assembly/shared/init.cmd
index aac92a6..019e4b8 100755
--- a/apache-maven/src/assembly/shared/init.cmd
+++ b/apache-maven/src/assembly/shared/init.cmd
@@ -83,12 +83,11 @@ cd /d "%EXEC_DIR%"
 
 :endDetectBaseDir
 
-set "jvmConfig=\.mvn\jvm.config"
-if not exist "%MAVEN_PROJECTBASEDIR%%jvmConfig%" goto endReadJvmConfig
+if not exist "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadJvmConfig
 
 @setlocal EnableExtensions EnableDelayedExpansion
-for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a
-@endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS%
+for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_OPTS=!JVM_CONFIG_MAVEN_OPTS! %%a
+@endlocal & set MAVEN_OPTS=%MAVEN_OPTS% %JVM_CONFIG_MAVEN_OPTS%
 
 :endReadJvmConfig
 
diff --git a/apache-maven/src/assembly/shared/run.cmd b/apache-maven/src/assembly/shared/run.cmd
index ab6da36..4e5b87a 100755
--- a/apache-maven/src/assembly/shared/run.cmd
+++ b/apache-maven/src/assembly/shared/run.cmd
@@ -1,5 +1,4 @@
 "%JAVACMD%" ^
-  %JVM_CONFIG_MAVEN_PROPS% ^
   %MAVEN_OPTS% ^
   %MAVEN_DEBUG_OPTS% ^
   -classpath %LAUNCHER_JAR% ^