ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dan Vint <>
Subject Testing properties with condition
Date Mon, 17 Dec 2007 16:25:45 GMT
I'm trying to use properties to control the processing within my 
script. I have several conditions that I want to test and based on 
them to stop further processing.

I think my problem lies with the not-set condition and how to handle 
this. I don't see anything in the documentation that indicates how 
<istrue> and <isfalse> should report an unset value, and I'm assuming 
isset returns true if set, but what does it return if not set?

So my big problem seems to be around using <available> to test if a 
file exists, so I have that set to true by default with

<available property='' file='foo.txt'/>

Then I test with the condition:

<condition property='continue-processing'>
	<isset property='${}/>
	<isset property="${Missing.File.Present}"/>
                <istrue property="$"/>

So the first 2 properties go true if I want to stop, so I'm thinking 
that isset works here, is really a reverse condition. If 
its set, I don't want to stop processing, so I have tires istrue and 
isset inside the not to try and make it false and that doesn't seem 
to be working.

Can anyone spot my logic probelm?

I'm using ant1.5 and can't easily change to something more current as 
there are a bunch of ant extensions that were created that I don''t 
have access to.

Danny Vint

Specializing in Panoramic Images of California and the West

voice: 510-522-4703

When H.H. Bennett was asked why he preferred to be out
shooting landscapes rather than spending time in his portrait studio:

"It is easier to pose nature and less trouble to please."


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message