Bug 5478 - Detecting 4NT in ant.bat
Detecting 4NT in ant.bat
Status: RESOLVED DUPLICATE of bug 3654
Product: Ant
Classification: Unclassified
Component: Build Process
1.4.1
PC All
: P3 normal (vote)
: ---
Assigned To: Ant Notifications List
:
Depends on:
Blocks:
  Show dependency tree
 
Reported: 2001-12-18 00:39 UTC by Eran Hadar
Modified: 2008-02-22 12:18 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eran Hadar 2001-12-18 00:39:59 UTC
I'm using 4NT301.
ant.bat tries to detect if it is running from 4NT shell by calling:
if "%eval[2+2]" == "4" goto setup4NT
on my 4NT version the command eval does not exits.
from the 4NT help files:

Detecting 4NT

From a batch file, you can determine if 4NT (or another JP Software command 
processor) is loaded by testing for the variable function @EVAL, with a test 
like this:

if "%@eval[2 + 2]%" == "4" echo 4NT is loaded!

This test can never succeed in CMD.EXE. Other variable functions could be used 
for the same purpose.


after adding the '@' every thing works fine.
I've failed to use the ant.bat for about half a day until I've found it.
Comment 1 Magesh Umasankar 2001-12-18 11:56:20 UTC

*** This bug has been marked as a duplicate of 3654 ***