-java -classpath<> <classname>
in the ".bat" file to launch java test from cmd windows
how to do that using perl to launch java test from linux ?
views:
39answers:
2
+1
A:
Don't use perl. For such a simple job, a simple shell script will do:
#!/bin/sh
/path/to/java -classpath foo.jar:bar.jar:. classname
Make the file executable with chmod +x filename
and execute it with ./filename
Paul Tomblin
2010-02-24 17:23:31
A:
A similar approach using the -jar
option is possible. Additionally, you can forward any command line parameters using the special parameter @
.
#!/bin/sh /path/to/java -jar foo.jar "${@}"
trashgod
2010-02-25 01:17:59