ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Larry V. Streepy, Jr." <>
Subject fail with if/unless support
Date Mon, 28 May 2001 23:00:53 GMT
In case anyone wants it, here is a copy of with support for
if/unless clauses.  This makes testing for required properties SOOOO
much easier.

Note that the attached file was modified from the ANT 1.3 release, not
the latest code from CVS, since I need my development environment to be
reasonably stable.

With the attached file, you can do things like this:

  <available property="wl.home.present" file="${wl.home}"/>
  <available property="src.dir.present" file="${src.dir}"/>
  <available property="JAVA_HOME.present" file="${env.JAVA_HOME}"/>

  <fail message="  **** Error: Environment var HOSTNAME is not present"

  <fail message="  **** Error: Environment var OS is not present"

  <fail message="  **** Error: ${wl.home} is not present"

  <fail message="  **** Error: ${src.dir} is not present"

Larry V. Streepy, Jr.
Chief Technical Officer and VP of Engineering

Health Language, Inc.  -- "We speak the language of healthcare"
A subsidiary of CyberPlus Corp.

970/626-5028 (office) 
970/626-4425 (fax)    
View raw message