ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dominique Devienne <>
Subject RE: order of <property file=...>'s and <property environment="env "...>, and usage of entity references
Date Wed, 21 Jan 2004 02:21:10 GMT
> From: Ray Tayek []
> hi, trying to develop a set of ant scripts for use as starting points in a
> small .com that makes web apps (mostly servlets and now a little web
> services). mostly getting ant and junit to play nice in netbeans and (and
> in
> eclipse rsn). i came up with the following order (based on maximum ability
> to override stuff:
> 	<property environment="env"/>
> 	<property file="${user.home}/"/>
> 	<property file=""/>

That's exactly what I'm doing too. Meaning that user properties have
Higher priority that project properties, and both can reference env.
Var. using the ${env.NAME} notation.

> then i noticed the sample build.xml in tomcat 5:
> 	<property file=""/>
> 	<property file="${user.home}/"/>
> 	<property environment="env"/>

Means users can't override project properties, except directly
On the command line, and that neither project or user properties
Can reference env. vars... This is wrong to me.

> also, it seems that a lot of stuff in build files is boiler plate (i know
> i
> can use refids's). iirc, there were some older threads on using xml entity
> references like:
> <?xml version="1.0"?>
> <!DOCTYPE project [
> 	<!ENTITY foo SYSTEM "../foo.xml">
> ]>
> ...
> <project ...
> ...
> ... &foo; ...
> ...
> </project>
> searched the arhives, but did not find much. does this stuff work? are
> there
> any weirdities to worry about? Is there some doc somewhere?
> any pointers will be appreciated.

Just use Ant 1.6 (1.6.1 is coming out soon) with an <import> that superceded
XML entity import. <import> further allows you to override a target from the
Imported build file. --DD

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

View raw message