ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Loughran <ste...@apache.org>
Subject Re: Ant dependencies task
Date Tue, 16 Aug 2005 09:20:36 GMT
Frank W. Zammetti wrote:
>>or you make every target conditional
>>
>>unless="compile.disabled"
>>
>>and then turn on and off on the command line
> 
> 
> For the way I work, this isn't feasible... I don't use an IDE, I use
> UltraEdit... I have a single keystroke that executes the script, and I
> don't have the opportunity to alter the command line (that's not
> *entirely* true... I *could* pass some things to it, but it's more trouble
> than it's worth).
> 


no, you create a build.properties file with all the various settings in, 
and load it in at the beginning of your build

build.properties:

compile.disabled=true

load this with
<property file="build.properties" />

you get the switching, you get the IDE support, you get proper ant 
dependency logic.

> 
>>declaring dependencies is the core of ant's dependency logic.
> 
> 
> Understood.  But, except for the dependency task this thread started
> about, my targets are all independant units, they aren't truly
> dependencies.  This is true of every script I've written to date.  No
> doubt it I had true dependencies I probably would change the way I do
> thing s:)

you've just introduced dependencies, havent you? All your tasks now 
depend upon the initial setup phase, which means there is nominally one 
target that your others depend on

> 
> I'm not especially worried about the performance hit, but not being able
> to pass information I could see burning me at some point certiainly.
> 
> 
>>Try the other way, try using dependencies. trust the runtime
>>
>>steve
> 
> 
> I do appreciate the suggestions Steve! :)  I'm fine for now, but I will
> keep in mind the things you said for when I reach the point where I'm not
> any more.
> 

I would recommend you start now, before you paint yourself into a 
corner. By the time you discover that things are in a mess, it is 
usually just before a deadline, the build is more complex, things are 
too late to fix, etc, etc. Learn the right way at the beginning, when 
the schedule pressure is least.

-steve

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


Mime
View raw message