ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jason Rosenberg" <ja...@squaretrade.com>
Subject Re: Parameterized "task-function"
Date Thu, 11 Jan 2001 19:32:24 GMT
Guys,

Over on the ant-dev mailing list, I've been raising the exact points
lately, and they all seem irrationally obstinate about it.  Then they
accuse me of being the only one out there who doesn't agree
with them, especially this Pete Donald character.  But the reality
is I am not alone in this, and now I am seeing others come out
of the woodwork.  I have received many private e-mails from
those who agree with me but are not interested in commenting
publically, and now I am seeing a lot more sane opinions being
addressed here on ant-user.

Keep it up, certainly, someone will get it in their heads, that
in order for Ant to go to the next level, these issues must be
addressed.

Jason

----- Original Message ----- 
From: "Rosen, Alex" <arosen@silverstream.com>
To: <ant-user@jakarta.apache.org>
Sent: Thursday, January 11, 2001 11:46 AM
Subject: RE: Parameterized "task-function"


> Maybe I'm missing something, but... to me this approach feels totally backward.
> It reminds me of the systems for simulating parameterized types with
> preprocessor macros, before C++ templates came along, which was an unnatural
> hack.
> 
> Sorry to say, what I really want to do is "call a method" - that's what would
> feel natural to me. What you're doing is adding a preprocessor, which feels
> backwards - the method comes first, then the method call, instead of the other
> way around.
> 
> I'm no language expert, but to me Ant (and building in general) feels like a
> declarative language on top of a procedural language. You want to use a
> declarative language to figure out what to build, but you really want to use a
> procedural language to describe how to build it. Trying to extend the
> declarativeness all the way down seems like a big mistake...
> 
> Is there anything declarative about describing how to build something (as
> opposed to describing what to build)?
> 
> Alex
> 
> > -----Original Message-----
> > From: Peter Donald [mailto:donaldp@apache.org]
> > Sent: Thursday, January 11, 2001 10:24 AM
> > To: ant-user@jakarta.apache.org
> > Cc: ant-user@jakarta.apache.org
> > Subject: Re: Parameterized "task-function"
> >
> > Usually a second file thou we could make it internal aswell I believe
> > without too much trouble. A possible example would be
> > (remembering that I
> > also hate XSLT so may have munged the syntax):
> >
> > <xsl:template match="build-jar">
> >   <javac srcdir="src/java/{@name}" destdir="build/{@name}"/>
> >   <jar jarfile="{@name}.jar" basedir="build/{@name}"/>
> >   <signjar jarfile="{@name}.jar" />
> >   <cab cabfile="{@name}.cab" basedir="build/{@name}"/>
> >   <signcab cabfile="{@name}.cab" />
> > </xsl:template>
> >
> > now somewherer in your build file you would have
> >
> > <target name="foo">
> >   <build-jar name="bean1" />
> >   <build-jar name="bean2" />
> >   <build-jar name="bean3" />
> > </target>
> >
> > This would compile, jar, cab and sign the three beans so that they are
> > ready for distribution via web-browser. This is just a simple
> > example but
> > it could get much more complex allowing you to do virtually
> > everything.
> > Kinda like some of those make builders ;) It is complex but
> > it brings power.
> >
> > Cheers,
> >
> > Pete
> >
> > *-----------------------------------------------------*
> > | "Faced with the choice between changing one's mind, |
> > | and proving that there is no need to do so - almost |
> > | everyone gets busy on the proof."                   |
> > |              - John Kenneth Galbraith               |
> > *-----------------------------------------------------*


Mime
View raw message