OK, I've taken the plunge. I've committed a scripting task to Ant.
If you like, think of it as a revolution. It is in a separate
subdirectory, and it is not included in the bootstrap or included in the
Ant build by default.
Or, if you prefer, think of it as a first step towards moving the non-core
tasks out of the "minimalist" version of Ant. Perhaps someday, we will
have two separate Jars.
In any case, below I've included a working script. It doesn't do anything
useful, but it does give an indication of what is possible.
<?xml version="1.0"?>
<project name="test" default="main">
<target name="main">
<property name="welcome" value="from BSF!" />
<echo message="hi there" id="echoTask"/>
<script language="javascript">
echoTask.setMessage(welcome)
echoTask.execute()
</script>
</target>
</project>
- Sam Ruby