Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Example app showing how to wire up Ruby classes with Google Guice.
Ruby Java
Branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.

Guice in your JRuby

Demonstrates how to wire up Ruby classes using Google Guice, including:

  • Constructor injection
  • Setter injection
  • Custom Guice module in Ruby

I wrote a blog post introducing the idea.

Getting Started

mvn package
java -jar target/jruby-guice-1.0.jar

If using an IDE, you may have to configure it to explicitly run mvn compile before running the project.

Start reading in src/main/java/net/rhnh/ and src/main/ruby/SimplestApp.rb.


Perhaps you are integrating Ruby into an existing Java framework. Standalone, this is a terrible idea.

Something went wrong with that request. Please try again.