[
http://jira.codehaus.org/browse/MNG-2178?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_86151
]
Alexander Veit commented on MNG-2178:
-------------------------------------
if "%OS%"=="Windows_NT" SET M2_HOME=%~dp0.. seems to be correct.
This bug is probably more severe than it might seem, since child processes
inherit the malformed path.
> incorrect M2_HOME guess in mvn.bat
> ----------------------------------
>
> Key: MNG-2178
> URL: http://jira.codehaus.org/browse/MNG-2178
> Project: Maven 2
> Issue Type: Bug
> Components: Bootstrap & Build
> Affects Versions: 2.0.2
> Environment: WXP
> Reporter: Jörg Henne
> Fix For: 2.0.x
>
>
> mvn.bat contains the following lines:
> :chkMHome
> if not "%M2_HOME%"=="" goto valMHome
> if "%OS%"=="Windows_NT" SET M2_HOME=%~dps0\..
> if not "%M2_HOME%"=="" goto valMHome
> Guessing M2_HOME=%~dps0\.. leads to complaints later on, since the script
> expects m2.bat in bin/...:
> if exist "%M2_HOME%\bin\m2.bat" goto init
> Hence, the line should read:
> if "%OS%"=="Windows_NT" SET M2_HOME=%~dps0\..\..
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira