ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dominique Devienne <DDevie...@lgc.com>
Subject RE: "if" task
Date Tue, 30 Apr 2002 15:50:30 GMT
So if you are not *against* including these tasks, admittedly useful to
many, who is, and on what grounds (behind the "scripty" notion, please!). Or
the ANT maintainers must clearly state that they do not want to support
building *any* kind of projects, *only* just pure Java ones.

So you've never written a task that depends on 3 others, the first one to
check a condition, the second executed if the check condition is true (thus
some property set or not!!!), and the third executed if the condition is
false??? All this resulting in a silly output like this:

...
check-execute-condition:
execute-if-condition-true:
execute-if-condition-false:
execute:

After you've written 4 targets instead of one, and confuse your users
nonsense output... if the execute target had a simple, elegant,
self-explanatory

<target name="execute">
	<if> check-execute-condition tasks
	</if>
	<then> execute-if-condition-true tasks
	</then>
	<else> execute-if-condition-false tasks
	</else>
</target>

you would get what any ANT newbie would expect. Show them what you have to
resort to now (the 4 targets, the depends attributes, the fast that the
result of the first dependencies influences the two others, the fact that
if/unless check for property existence rather than "true" value, etc...),
and compare that to the expressiveness of <if><else><then>! I bet the
current ANT way will *not* come on top!!!

--DD

PS: guess I must be grumpy this morning...

-----Original Message-----
From: Erik Hatcher [mailto:jakarta-ant@ehatchersolutions.com] 
Sent: Tuesday, April 30, 2002 10:35 AM
To: Ant Users List
Subject: Re: "if" task

Just to clarify, I'm actually +0 on adding those tasks to Ant's core.  I've
given the ones from ant-contrib a try and they are well done and certainly
would be useful to many.  I've not found a need for them in any of my builds
to-date though, but I'm also only doing pure Java development mostly for
building webapps.

    Erik

----- Original Message -----
From: "Dominique Devienne" <DDevienne@lgc.com>
To: "'Ant Users List'" <ant-user@jakarta.apache.org>
Sent: Tuesday, April 30, 2002 11:29 AM
Subject: RE: "if" task


> This scripty notion is just plain silly. You almost always have to do
builds
> conditionally. That's why make has them, and that's why ANT has them too,
> albeit in a very ugly way by means of <condition>/properties and
> if/unless/os on targets and other things too. Even Diane, the person who
> gives the best advise on ANT, seems to think <if>/<foreach>/<trycatch>
are
> more than worthwhile, and their use makes build files 100 times better
> structured than all these targets if/unless/os triggered by properties,
> etc...
>
> The objective to encapsulate all conditional/repetitive processes into
tasks
> is great, and ANT has made good progress on many tasks, but preventing all
> ANT users out there of clean and elegant conditional/repetitive execution
of
> tasks, well that's being very blind to users need. People will prototype
> their build processes with <if>/<foreach>/etc... and later streamline it
> into a cleaner task or two.
>
> Just try putting to a vote the inclusion of <if>/<foreach> into ANT core
to
> ANT *users*!!! These are still XML, are XSLT transformable, are clean and
> elegant. They just formalize into a very natural way what ANT already does
> (in a very inelegant way). Meritocracy shouldn't mean dismissing the need
of
> a very sizeable chunk of the ANT user community.
>
> --Dominique "scripty" Devienne
>
> -----Original Message-----
> From: Erik Hatcher [mailto:jakarta-ant@ehatchersolutions.com]
> Sent: Tuesday, April 30, 2002 4:31 AM
> To: Ant Users List
> Subject: Re: "if" task
>
> Write your builds in Perl if you want "scripty".
>
> Hey, even call Ant from there if you like.  :))
>
> By the way, there is a <script> task too.
>
>     Erik
>
> ----- Original Message -----
> From: "Dave Bettin" <javabettin@yahoo.com>
> To: "Ant Users List" <ant-user@jakarta.apache.org>
> Sent: Tuesday, April 30, 2002 12:04 AM
> Subject: Re: "if" task
>
>
> >
> > > It's considered too "scripty".
> >
> >  What is the motivation to keep ant from being to
> > "scripty"?
> >
> > Thanks,
> > Dave
> >
> > __________________________________________________
> > Do You Yahoo!?
> > Yahoo! Health - your guide to health and wellness
> > http://health.yahoo.com
> >
> > --
> > To unsubscribe, e-mail:
<mailto:ant-user-unsubscribe@jakarta.apache.org>
> > For additional commands, e-mail:
<mailto:ant-user-help@jakarta.apache.org>
> >
> >
>
>
> --
> To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>
>
> --
> To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>
>
>


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

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


Mime
View raw message