IAmYourFaja
IAmYourFaja

Reputation: 56904

Why does Ant recognize some env vars but not others

I have 2 env vars defined:

myuser@mymachine:~$ echo $ANT_HOME
/home/myuser/apache/ant/1.8.4/apache-ant-1.8.4
myuser@mymachine:~$ echo $ANT_IVY_HOME
/home/myuser/apache/ivy/apache-ivy-2.3.0-rc2

I have the following Ant build:

<property environment="env"/>

<target name="testant">
    <echo message="Ant home: ${env.ANT_HOME}"/>
    <echo message="Ant ivy home: ${env.ANT_IVY_HOME}"/>
</target>

When I run testant I get the following console output:

Buildfile: /home/myuser/eclipse/workspace/myapp/build.xml
testant:
    [echo] Ant home: /home/myuser/apache/ant/1.8.4/apache-ant-1.8.4
    [echo] Ant ivy home: ${env.ANT_IVY_HOME}
BUILD SUCCESSFUL
Total time: 316 milliseconds

Why does Ant recognize ANT_HOME but not ANT_IVY_HOME? Thanks in advance!

Upvotes: 0

Views: 75

Answers (1)

smooth reggae
smooth reggae

Reputation: 2219

Did you merely set ANT_IVY_HOME and not export it?

Upvotes: 2

Related Questions