<project default="java:compile" xmlns:j="jelly:core" xmlns:u="jelly:util" xmlns:ant="jelly:ant">
<goal name="bsh">
<attainGoal name="java:jar-resources"/>
<attainGoal name="java:compile"/>
<ant:java classname="bsh.Console" fork="true">
<ant:classpath>
<ant:path refid="maven.dependency.classpath"/>
<ant:pathelement path="${maven.build.dest}"/>
</ant:classpath>
</ant:java>
</goal></project>
Which appears to do what I want. (You can change "bsh.Console" above to "bsh.Interpreter" if you don't want a windowed interface)
Hopefully some of you will find it useful.
-james
James A. Hillyerd wrote:
I'm looking for a way to launch BeanShell (or Groovy, either one will work for me) from Maven. My goal is to have an interactive scripting shell with a classpath containing all of my project's dependencies, and "target/classes" itself.
I'm new to Maven, it's not something I can figure out how to do myself. I've searched the web for an example but there was a lot of noise in the results since Groovy uses Maven to build, and Maven supports(?) writing plugins in BeanShell.
Has anyone done this? It seems like it would make a really useful maven plugin, since it would let you test ideas without writing experimental classes and launch scripts, etc.
Thanks!
-james
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
