ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject svn commit: r454794 - /ant/core/trunk/src/script/ant.bat
Date Tue, 10 Oct 2006 15:53:47 GMT
Author: mbenson
Date: Tue Oct 10 08:53:45 2006
New Revision: 454794

support %HOMEDRIVE%%HOMEPATH% on XP. Bugzilla 39298.


Modified: ant/core/trunk/src/script/ant.bat
--- ant/core/trunk/src/script/ant.bat (original)
+++ ant/core/trunk/src/script/ant.bat Tue Oct 10 08:53:45 2006
@@ -21,8 +21,15 @@
 REM Be cautious about editing this, and only add WinNT specific stuff in code that
 REM only runs on WinNT.
+if "%HOME%"=="" goto homeDrivePathPre
 if exist "%HOME%\antrc_pre.bat" call "%HOME%\antrc_pre.bat"
+if "%HOMEDRIVE%%HOMEPATH%%"=="" goto alpha
+if exist "%HOMEDRIVE%%HOMEPATH%\antrc_pre.bat" call "%HOMEDRIVE%%HOMEPATH%\antrc_pre.bat"
 if "%OS%"=="Windows_NT" @setlocal
 if "%OS%"=="WINNT" @setlocal
@@ -174,27 +181,32 @@
 rem bug ID 32069: resetting an undefined env variable changes the errorlevel.
-set _JAVACMD=
+if not "%_JAVACMD%"=="" set _JAVACMD=
+if not "%_ANT_CMD_LINE_ARGS%"=="" set ANT_CMD_LINE_ARGS=
+if "%ANT_ERROR%"=="0" goto mainEnd
 rem Set the return code if we are not in NT.  We can only set
 rem a value of 1, but it's better than nothing.
-if not "%OS%"=="Windows_NT" if "%ANT_ERROR%"=="" set ANT_ERROR=255
-if not "%OS%"=="Windows_NT" if "%ANT_ERROR%"=="0" goto quit
 if not "%OS%"=="Windows_NT" echo 1 > nul | choice /n /c:1
 rem Set the ERRORLEVEL if we are running NT.
-if "%OS%"=="Windows_NT" if "%ANT_ERROR%"=="" set ANT_ERROR=255
-if "%OS%"=="Windows_NT" if not %ANT_ERROR%==0 color 00
-goto quit
+if "%OS%"=="Windows_NT" color 00
+goto omega
 rem If there were no errors, we run the post script.
 if "%OS%"=="Windows_NT" @endlocal
 if "%OS%"=="WINNT" @endlocal
+if "%HOME%"=="" goto homeDrivePathPost
 if exist "%HOME%\antrc_post.bat" call "%HOME%\antrc_post.bat"
+if "%HOMEDRIVE%%HOMEPATH%"=="" goto omega
+if exist "%HOMEDRIVE%%HOMEPATH%\antrc_post.bat" call "%HOMEDRIVE%%HOMEPATH%\antrc_post.bat"

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message