ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eric Rosengren <eric.roseng...@rtswireless.com>
Subject RE: Accessing environment variables
Date Thu, 12 Apr 2001 15:22:50 GMT
There are many better examples in the achieves of this newgroup, but here's
what I do.

  <property environment="env" />
  <property name="javapath"  value="${env.JAVA_HOME}"/>

You don't have to use the string "env". You can call it anything you'd like.


-----Original Message-----
From: Jim Downing [mailto:jimdowning@crosswinds.net]
Sent: Thursday, April 12, 2001 11:17 AM
To: ant-user@jakarta.apache.org
Subject: Accessing environment variables


Hi.
I'm a complete Newbie to Ant. I'm trying to construct a simple ant build
file to replace the script based approach I was using. Is it possible to
access OS 
environment variables (such as JAVA_HOME) as properties in build.xml, or do
you have to re-specify them fully as properties in build.xml?

thanks,
Jim

Mime
View raw message