Les Hazlewood wrote:

 > Please! Use standard ant "semantics" - first time you set a
 > property you
 > cannot change it again. Thus your loading sequence must be
 > reversed! First ${user.home} then etc.

Sure you can! You can override property definitions in Ant...

What version of Ant are you using !?! Please try to run the following with any Ant 1.x.x


<?xml version="1.0" encoding="ISO-8859-1" ?>

<project name="application" default="build" basedir=".">

<target name="init">
        <echo>0: ${a.property}</echo>
        <property file="build.properties"/>
        <echo>1: ${a.property}</echo>
        <property file="build2.properties"/>
        <echo>2: ${a.property}</echo>
        <property name="a.property" value="last"/>
        <echo>2: ${a.property}</echo>       
</target>

</project>

And then tell me what you see if build.properties contains a.property=first ?

My bet (and the CORRECT behavior) is:

init:
     [echo] 0: ${a.property}
     [echo] 1: first
     [echo] 2: first
     [echo] 2: first

BUILD SUCCESSFUL
Total time: 1 second

Notice that the possible assignment from build2.properties or the explicit property is IGNORED if the property is already defined!

So, please load ${user.home} etc. first!

The user should only have to specify the properties they want that are different from the standard build (if any).

For example:

Lets say I'm happy with all the standard libraries that hibernate provides, but I want to try a new library out. Say I download the latest snapshot of commons-lang.jar from the Jakarta website. Naturally, this snapshot will be more up to date than the one provided by Hibernate, since its newer. So, if it is the only file I want to compile Hibernate against that is different than the default jars, I could have a single entry in my ${user.home}/hibernate.build.properties file:

commons-lang.jar = /my/local/path/to/commons-lang.jar

Every other build dependency would use the standard libraries as specified in Hibernate's default build.properties file.

Isn't this desireable?

Les




------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel

Reply via email to