So I’ve been toying around with the RubyGems Maven Support in JRuby
1.6.0.RC1
(http://www.engineyard.com/blog/2011/jruby-1-6-0-rc1-released/),
and I’m getting weird errors trying to install anything. From what it
looks
like, it doesn’t know to go to a maven repository to get the :
PS C:\mydocs> jruby -S gem install joda-time:joda-time -V
GET RubyGems.org | your community gem host
302 Found
GET http://production.s3.rubygems.org/latest_specs.4.8.gz
200 OK
ERROR: Could not find a valid gem ‘joda-time:joda-time’ (>= 0) in any
repository
Is there anything I need to set in my ~/.gemrc to get maven to integrate
with JRuby? My .gemrc looks like this currently:
PS C:\mydocs> jruby -S gem env
RubyGems Environment:
- RUBYGEMS VERSION: 1.4.2
- RUBY VERSION: 1.8.7 (2011-01-10 patchlevel 330) [java]
- INSTALLATION DIRECTORY: C:/jruby-1.6.0.RC1/lib/ruby/gems/1.8
- RUBY EXECUTABLE: C:/jruby-1.6.0.RC1/bin/jruby.exe
- EXECUTABLE DIRECTORY: C:/jruby-1.6.0.RC1/bin
- RUBYGEMS PLATFORMS:
- ruby
- universal-java-1.6
- GEM PATHS:
- C:/jruby-1.6.0.RC1/lib/ruby/gems/1.8
- C:/mydocs/.gem/jruby/1.8
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :benchmark => false
- :backtrace => false
- :bulk_threshold => 1000
- “install” => “–env-shebang”
- “update” => “–env-shebang”
- :sources => [“http://gems.rubyforge.org/”]
- REMOTE SOURCES:
We have a corporate Nexus repository that we have our settings.xml
mirroring
all requests to, which works great for our Java projects, but I don’t
know
how to configure JRubyGems to use it when requesting a maven dependency.
Any tips, steps, or things I am probably just not doing to get Maven to
play nice with JRuby?
-Nick