Take a look at the <property> task with the environment="env" attribute to
allow to access the OS enviroment variables as ANT properties
You should be able to do the following
<property environment="env"/>
<echo message="FOP_HOME value is ${env.FOP_NAME}"/>
Note the names of the created properties will be case-sensitive to the name of
the OS environment variables.
later,
Ninju
----- Original Message ----
From: [EMAIL PROTECTED]
To: [email protected]
Sent: Friday, December 16, 2005 3:07:43 PM
Subject: Access to OS environment variables?
Am I just looking in the wrong place, or is there no way to read or capture the
value of an operating system environment variable from within an ant build
file. For example. I would like to use the fop task, but in order to do so I
must create a property named "fop.dir" and enter the path to my fop .jar
files. Since I already have an FOP_HOME environment variable, I'd like to
extract the value of that from the OS and place it "value" attribute of the
aforementioned property element.
--
Charles Knell
[EMAIL PROTECTED] - email
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]