Hi,

Last night I thought I would be great to avoid to start JVM and to parse the
Ant build file each time I want to do a build. I know that there is an
ongoing effort called 'antidote' but I was thinking rather about a command
line tool.

And that's how Ant Shell (antsh) is born :-)

Ant Shell is a command line tool with build targets as the shell commands.
It has also (at the moment) 2+1 additional commands: exit, and help - which
does the same as Ant run with '-projecthelp' option. When you just hit
"enter" the last used target(s) (shown in square brackets in antsh prompt)
will be used (that's where the trick is :-). If the commands are targets you
may run several at the same time (just like with Ant) - they are
space-separated (just like with Ant :-).

Its main purpose is not to be a full-featured shell (like bash for example)
but rather to offer some basic functionalities and especially to avoid to
start JVM and parse build file each time.

Implementation:
The current implementation is far from being the state of the art - it's
much more a prototype and a proof of concept. I just took the Ant's "Main"
class, renamed it and changed it slightly. I had also to leave it in
"org.apache.tools.ant" package as it uses some protected methods (ex.
Project.fireXXX).


I would like to know your thoughts about it. Please try it (attached to this
message) and tell me if the tool like this makes sense, and if yes, what are
the other features that would be useful. I might become the Ant's
interactive mode (ex. ant -interactive).

If you think antsh is useful I'd love to do a clean implementation and add
all the demanded features.


It was done with Ant 1.2, JDK 1.3, Win2000. I haven't test it - just built a
couple of targets. To install it unzip the file in the ANT_HOME directory.
If you want to look at the source code - it's in antsh.jar.
You use it exactly the same way as Ant - the command name is "antsh" instead
of "ant".

There is also a screenshot :-) - "antsh[_last_targets_]> " is the antsh
prompt.


Best Regards,
Slawek Zachcial

<<attachment: antsh.zip>>

<<attachment: antsh-screenshot.gif>>

Reply via email to