What is wrong with me
Go to file
R. Tyler Croy 4e4efe8ade Add a Rakefile to make this sucker runnable 2014-08-10 15:32:31 -07:00
gradle/wrapper Initial commit 2014-07-25 13:52:45 -07:00
src/main/webapp/WEB-INF Add a Rakefile to make this sucker runnable 2014-08-10 15:32:31 -07:00
.gitignore Create a runnable war file using the WarMain from warbler 2014-07-28 13:30:11 -07:00
README.md Add system requirements to the readme 2014-07-28 16:45:29 -07:00
build.gradle Restructure the project to rely on the jruby-gradle-plugin 2014-08-10 13:15:55 -07:00
gradlew Initial commit 2014-07-25 13:52:45 -07:00

README.md

Ruby + Gradle Example

This project relies heavily on the marvelous TorqueBox Rubygems Maven repo.

Usage

In order to prepare the dependencies for the JRuby application you must invoke gradle:

% ./gradlew war

This will do a few things:

  1. Resolve Ruby gem dependencies
  2. Resolve Java dependencies
  3. Extract Ruby gems into vendor/
  4. Cache jars into .jarcache/ (for easily referencing at JRuby interpreter runtime)
  5. Create a runnable .war of what's in src/main/webapp

Alternatively you can run:

% ./gradlew jettyRunWar

Which will do all of the above and also run the war locally on port 8080

Running locally

% PATH=./vendor/bin:$PATH GEM_HOME=./vendor rackup src/main/webapp/WEB-INF/config.ru

Requirements

  • JRuby (for one form of local development)
  • Rubygems (gem) for extracting gems
  • Java 7