ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: [PATCH] Support for default ProjectHelper to expand properties in attributes to project/target tags
Date Wed, 07 Jan 2004 10:03:07 GMT
On Sun, 4 Jan 2004, Kenneth Olving <Kenneth.Olving@frameworx.com>
wrote:

> Hoping that I've managed to navigate all the etiquette for posting a
> patch, here goes:

I think you have.

> Change made in brief: The default ProjectHelper
> (ProjectHelper2.java) has had two lines changed so when parsing
> attributes for the project/target tags, values will be passed
> through Project.replacePropeties().

Historically, this has been proposed a few times and rejected by at
least one Ant committer every time it came up.  Traditionally it has
been Peter Donald who isn't active in Ant these days, but Jose Alberto
seems to have accepted the job for this specific issue 8-)

Allowing this for attributes on the <project> element doesn't look to
dangerous, but doing so for target is different issue.  If we start to
expand properties here, people will expect to see the run time value
of the property and not the parse time property.  I.e.

<target name="xyzzy"/>
<target name="bar">
  <property name="baz" value="xyzzy"/>
</target>
<target name="foo" depends="bar,${baz}"/>

people would expect xyzzy to get executed (it won't with your patch,
Ant will fail because no target ${baz} exists instead).  This would
break the static target dependency analysis for Ant.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message