Packaging Ruby as JAR Library

Sorry for the beginner question.

Does JRuby current have the ability to package ruby code as a JAR that
can be used by standard Java applications?

Thank you.

Mike H.


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

On Aug 19, 2008, at 10:47 AM, Mike H. wrote:

Sorry for the beginner question.

Does JRuby current have the ability to package ruby code as a JAR
that can be used by standard Java applications?

Thank you.

Mike H.

This isn’t built in, although you can pretty easily use jrubyc to
compile your ruby down to .class files and then jar them as normally.
Also, we have built Rawr, a tool for packaging up your app into a jar,
installing a Java main file so it’s double-clickable and even putting
a .exe or .app front end on the thing for “native” deployment.

http://rubyforge.org/projects/rawr/

David K.


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Mike H. wrote:

Sorry for the beginner question.

Does JRuby current have the ability to package ruby code as a JAR that
can be used by standard Java applications?

If you use one of the scripting APIs (BSF or javax.script) then yes,
it’s very easy to launch Ruby code that’s loaded from within a JAR. Is
that what you’re looking to do?

  • Charlie

To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

If you’re looking to package up your application as a jar file that
can be launched with java -jar myapp.jar then you could use Rawr to do
that.

http://rubyforge.org/projects/rawr/

David K.

On Aug 30, 2008, at 2:26 PM, Charles Oliver N. wrote:


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email