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 2018/05/07 21:44:59 UTC
[maven] branch master updated: [MNG-5756] Java home output in mvn
-v is misleading
This is an automated email from the ASF dual-hosted git repository.
michaelo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven.git
The following commit(s) were added to refs/heads/master by this push:
new 9abfc88 [MNG-5756] Java home output in mvn -v is misleading
9abfc88 is described below
commit 9abfc88425601da4e756a80768c2215bb97e9725
Author: Michael Osipov <mi...@apache.org>
AuthorDate: Sun May 6 00:01:55 2018 +0200
[MNG-5756] Java home output in mvn -v is misleading
The Java home displayed corresponds to the property 'java.home' which points to
the JRE installation running the given Maven instance. It is not the value of
$JAVA_HOME which causes confusion.
Ref: https://docs.oracle.com/javase/tutorial/essential/environment/sysprop.html
This closes #115 and #117.
---
.../src/main/java/org/apache/maven/cli/CLIReportingUtils.java | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/maven-embedder/src/main/java/org/apache/maven/cli/CLIReportingUtils.java b/maven-embedder/src/main/java/org/apache/maven/cli/CLIReportingUtils.java
index 52f2053..e1a4c2f 100644
--- a/maven-embedder/src/main/java/org/apache/maven/cli/CLIReportingUtils.java
+++ b/maven-embedder/src/main/java/org/apache/maven/cli/CLIReportingUtils.java
@@ -63,12 +63,11 @@ public final class CLIReportingUtils
properties.getProperty( "distributionShortName" ) + " home: " + System.getProperty( "maven.home",
"<unknown Maven "
+ "home>" ) ) )
- .append(
- ls );
+ .append( ls );
version.append( "Java version: " ).append(
System.getProperty( "java.version", "<unknown Java version>" ) ).append( ", vendor: " ).append(
- System.getProperty( "java.vendor", "<unknown vendor>" ) ).append( ls );
- version.append( "Java home: " ).append( System.getProperty( "java.home", "<unknown Java home>" ) ).append( ls );
+ System.getProperty( "java.vendor", "<unknown vendor>" ) ).append( ", runtime: " ).append(
+ System.getProperty( "java.home", "<unknown runtime>" ) ).append( ls );
version.append( "Default locale: " ).append( Locale.getDefault() ).append( ", platform encoding: " ).append(
System.getProperty( "file.encoding", "<unknown encoding>" ) ).append( ls );
version.append( "OS name: \"" ).append( Os.OS_NAME ).append( "\", version: \"" ).append( Os.OS_VERSION ).append(
--
To stop receiving notification emails like this one, please contact
michaelo@apache.org.