Skip to content

Instantly share code, notes, and snippets.

@andywer
Created December 9, 2013 22:04
Show Gist options
  • Save andywer/7881831 to your computer and use it in GitHub Desktop.
Save andywer/7881831 to your computer and use it in GitHub Desktop.
JRuby + Gradle + Bundler
andy@ubuntu-vostro:~/workspace/index-vivus$ ./gradlew ruby -PcmdArgs='-S bundle install'
:backend:compileJava UP-TO-DATE
:backend:processResources UP-TO-DATE
:backend:classes UP-TO-DATE
:frontend:ruby
/home/andy/workspace/index-vivus/frontend/ruby/jruby-1.7.8/bin/jruby --1.9 -J-cp /home/andy/.gradle/caches/modules-2/files-2.1/com.google.guava/guava/13.0.1/d6f22b1e60a2f1ef99e22c9f5fde270b2088365/guava-13.0.1.jar:/home/andy/.gradle/caches/modules-2/files-2.1/log4j/log4j/1.2.17/5af35056b4d257e4b64b9e8069c0746e8b08629f/log4j-1.2.17.jar:/home/andy/workspace/index-vivus/backend/build/classes/main:/home/andy/workspace/index-vivus/backend/build/resources/main -S bundle install
Gem::LoadError: Could not find 'bundler' (>= 0) among 0 total gem(s)
to_specs at /home/andy/workspace/index-vivus/frontend/ruby/jruby-1.7.8/lib/ruby/shared/rubygems/dependency.rb:298
to_spec at /home/andy/workspace/index-vivus/frontend/ruby/jruby-1.7.8/lib/ruby/shared/rubygems/dependency.rb:309
gem at /home/andy/workspace/index-vivus/frontend/ruby/jruby-1.7.8/lib/ruby/shared/rubygems/core_ext/kernel_gem.rb:47
(root) at /usr/local/bin/bundle:18
:frontend:ruby FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':frontend:ruby'.
> Process 'command '/home/andy/workspace/index-vivus/frontend/ruby/jruby-1.7.8/bin/jruby'' finished with non-zero exit value 1
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 13.408 secs
(Also tried './gradlew ruby -PcmdArgs='-S bundle -i frontend/ruby/gems install''. Same error...)
@andywer
Copy link
Author

andywer commented Dec 9, 2013

'./gradlew ruby -PcmdArgs='-S gem env'' tells:

RubyGems Environment:

  • RUBYGEMS VERSION: 2.1.9
  • RUBY VERSION: 1.9.3 (2013-11-14 patchlevel 392) [java]
  • INSTALLATION DIRECTORY: /home/andy/workspace/index-vivus/frontend/ruby/gems
  • RUBY EXECUTABLE: /home/andy/workspace/index-vivus/frontend/ruby/jruby-1.7.8/bin/jruby
  • EXECUTABLE DIRECTORY: /home/andy/workspace/index-vivus/frontend/ruby/gems/bin
  • SPEC CACHE DIRECTORY: /home/andy/.gem/specs
  • RUBYGEMS PLATFORMS:
    • ruby
    • universal-java-1.6
  • GEM PATHS:
    • /home/andy/workspace/index-vivus/frontend/ruby/gems
  • GEM CONFIGURATION:
    • :update_sources => true
    • :verbose => true
    • :backtrace => false
    • :bulk_threshold => 1000
    • "install" => "--no-rdoc --no-ri --env-shebang"
    • "update" => "--no-rdoc --no-ri --env-shebang"
  • REMOTE SOURCES:
  • SHELL PATH:
    • /home/andy/workspace/index-vivus/frontend/ruby/jruby-1.7.8/bin
    • /home/andy/workspace/index-vivus/frontend/ruby/gems/bin
    • /home/andy/workspace/index-vivus/frontend/railsapp
    • /usr/local/heroku/bin
    • /usr/lib/lightdm/lightdm
    • /usr/local/sbin
    • /usr/local/bin
    • /usr/sbin
    • /usr/bin
    • /sbin
    • /bin
    • /usr/games
    • /home/andy/.rvm/bin
    • /home/andy/.composer/vendor/bin
    • /home/andy/ns-allinone-2.35/bin
    • /home/andy/ns-allinone-2.35/tcl8.5.10/unix
    • /home/andy/ns-allinone-2.35/tk8.5.10/unix
    • /home/andy/ns-allinone-2.35/ns-2.35/
    • /home/andy/ns-allinone-2.34/nam-1.15/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment