aspose file tools*
The moose likes Ruby and the fly likes Automating Inclusion of Required Ruby Modules in JRuby Jar Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Languages » Ruby
Bookmark "Automating Inclusion of Required Ruby Modules in JRuby Jar" Watch "Automating Inclusion of Required Ruby Modules in JRuby Jar" New topic
Author

Automating Inclusion of Required Ruby Modules in JRuby Jar

Dan King
Ranch Hand

Joined: Mar 18, 2009
Posts: 84
Is it possible to automate the inclusion of required Ruby modules in (JRuby) jars? Currently, I'm manually copying module files into a 'lib' directory within the main project directory from which I create a jar. I posed this question on the jruby mailing list and I was advised that 'warbler' can automate the process. However, it appears 'warbler' automates the jar creation process, but not the inclusion of required module files.
Marc Peabody
pie sneak
Sheriff

Joined: Feb 05, 2003
Posts: 4727

Assuming that by modules you mean gems, then Bundler is your best bet:
http://gembundler.com/
Rails 3 ships with Bundler. If you're not using Rails 3, you can still install Bundler as a gem.

A normal bundle install will only save gems to your local system. However a bundle package will include the gems in the project itself:
http://gembundler.com/bundle_package.html

You will likely still use warbler but do so after running bundler.


A good workman is known by his tools.
 
Don't get me started about those stupid light bulbs.
 
subject: Automating Inclusion of Required Ruby Modules in JRuby Jar