ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nico Seessle" <n...@seessle.de>
Subject Re: Can I print value of properties....
Date Thu, 21 Sep 2000 23:33:50 GMT
----- Original Message -----
From: "D'Souza, Sudeep" <Sudeep.DSouza@gs.com>
To: "Ant user (E-mail)" <ant-user@jakarta.apache.org>
Sent: Friday, September 22, 2000 1:19 AM
Subject: Can I print value of properties....


> Hi,
> I want some of the values of my properties to be echoed on the
> screen.... If I use the echo it is just printing the string as it is as in
> ${what_ever}. While doing development how do I add debug statements, for
> example statements that print out the classpath so that I know that the
> classpath is right or not when the build is running.
>

In Ant1.1 the bejaviour for properties are only resolved once (while parsing
your buildfile), all usages of <property/> will be "executed" while parsing
independet of where you place them. If you build-file (or the  echo-task)
prints ${what_ever} for your property then this is it's value (and will be
for all usages inside the same 'instance' of the build-file). If you need
more dynamic behaviour you can try to use one of the nightly builds or have
a look at the 'antcall'-task which reparses your file and allows you to
dynamically define properties using nested <param/>-tags (if they are not
already defined in your buildfile).

You should think of one of the nightly builds, even if they are development
builds and not stable builds they should be much more 'stable' (in the sense
of quality, not in the sense of changing their behaviour from day to day)
and probably contain less bugs than 1.1 (even if it may be possible that new
bugs were introduced and no one has found them).

Nico



Mime
View raw message