ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jesse Tilly <>
Subject RE: Role of scripts [was Re: increment task]
Date Thu, 26 Oct 2000 20:25:54 GMT
Since everyone else has made some comments, I felt "what the heck", opinions
are cheap.

(1) I feel Ant should have the "on-the-fly" flexibility scripts give.
Having to write a new task definition just to do some small bit of
functionality, above and beyond a current task is not feasible whether you
know Java or not.

(2) The immaturity (and it is immature) of Ant means that not every task is
complete.  Some things we need to be patient about.  EJBJAR is *far* from
being complete, in my opinion.  I need <exec> and <script> to do things I
can't do in EJBJAR.  When EJBJAR has all the features I want (and I'm trying
to add them during my oh-so large amounts of free time) then I can ditch the
<script>...because I *want* no script in there.

(3) Scripts (and exec to some extent) break the intent of Ant and XML.  You
can't argue against that point very much when you think about XML.  XML is
an element based file meant to uniformly describe data/information.  Exec
follows this pattern, so it's excused.  Script works more like HTML, where
tags simply describe how that which is in-between should be read.  The long
rope of XML is being tied into a noose if you follow that path.

(4) 2 and 3 can't be rectified now.  People needing to get work done (like
Diane) use scripting because time and effort are efficiently used.  People
wanting to extend Ant should look at what Diane is doing with scripting and
make sure their elements handle those cases in one way or another.  Sort of
the "build the lawn, watch for the paths to form, then lay the sidewalks"
way of architecting Ant.  

(5) I can offer a suggestion that may aid script builders and java extenders
alike.  Have an Ant process (this can be outside of the actual main Ant
class, and probably should be) that can take a file containing a <script>
set, and turn it into a class accessible via taskdef and usable in the Ant
build file.  Sort of like using JSP to write servlets.  Obviously, this
can't be completed overnight, but I think it's worth discussing as (a) a
good compromise between the script writers and the Java extenders and (b) a
way to make task writing easier since 20% of the code is identical for every
task.  Thoughts?


-----Original Message-----
From: Alan Gerhard [mailto:AGerhard@E-SyncNet.Com]
Sent: Thursday, October 26, 2000 3:25 PM
Subject: RE: Role of scripts [was Re: increment task]

We are loosing the focus here. 
Regardless of what the *original* intent was, the end result is that we, the
ANT Community, have an open source, platform independent, MAKE tool that is
extremely light weight and flexible.

It's written in JAVA and supports on open interface that allows extended and
custom *java* tasks to be plugged in relatively easily - as long as one has
the ability to program using java.

And this is where scripts come into play. Now I am trying to understand what
Diane meant by supporting JavaScript and the best I can do is the following

Ant is a program that interprets an xml-base script language and performs
the actions thus requested by it. Instead of relying on the limitations of
the Ant Language and custom java classes, couldn't Ant interpret other
*languages* too ?? 

This is more in line with Sam's comments about *language independence*, but
let's not kid ourselves - Ant uses an XML-based language, and yes, it's a

This is how I understand the request for script support.

With this in mind, the question really is - "Do we want to create an
interface that allows for multiple *languages*, or parsers ??

Alan Gerhard

-----Original Message-----
|From: Sam Ruby/Raleigh/IBM []
|The original concept was language independent.  The implementation and the
|first set of tasks were written in Java because that's what James Duncan
|Davidson needed at the time.
|James, Stefano, myself or the others at the time would have no objections
|to Ant being extended by COBOL or LISP or whatever.
|What everybody didn't want was for the Ant language itself (by this, I mean
|the XML grammar) to become yet another programming language.
|- Sam Ruby

View raw message