ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <dona...@apache.org>
Subject Re: beanshell
Date Sun, 12 Nov 2000 03:14:45 GMT
At 12:15  11/11/00 -0800, you wrote:
>Since i'm new to the list, i'm not sure what sort of discussion has already
>happened around adding BeanShell support to Ant. Can anyone catch me up real
>quick?
>
><http://www.beanshell.org/>

The best thing IMO would be to use Bean Scripting Framework from IBM. It is
really groovy and covers is an interface to a lot of scripting languages
(unfortunately beanshell is not one of them). You can already use BSF to do
practically anything you can do in java.

>If no discussion has happened, I would like to propose that we add BeanShell
>support to Ant. What I would like to do is essentially use BeanShell as a
>replacement for the complex .sh/.bat files that we have to use to go along
>with execution of Ant.

Just curious but is this for turbine .sh/.bat files. If so I would be happy
to show you how to change them so that they are simple one liners. At one
stage I had all the turbine scripts with but a few lines and could probably
do that again if you want. 

There are currently 2 things lacking that are not currently possible from
ant (yet). First and most importantly is dynamically loading
taskdefinitions from a specific jar file after compiling it. While this was
done for simple case (where you just need to compile one class) it does not
work for complex taskdefs which have multiple interwoven dependencies.
Someone has provided a patch to get this to work but it hasn't been added
into CVS yet and I think there was a few issues that needed to be worked
out first.

The other problem is grabbing environment variables which is simply
impossible from java (at least in a cross platform manner). Some one I
believe sent a patch (or at least suggested) that you run a script that
would automagically import all shell variables as java system properties.
So if you had a shell variable CLASSPATH it would be avaialable as
"env.CLASSPATH". I know how to do this on *nix but not sure if it is
possible under win9x so ....

If there is any other demands you need feel free to suggest em ;)

Cheers,

Pete

*------------------------------------------------------*
| "Nearly all men can stand adversity, but if you want |
| to test a man's character, give him power."          |
|       -Abraham Lincoln                               |
*------------------------------------------------------*

Mime
View raw message