Open deivid-rodriguez opened 8 years ago
Could you provide me with an error message? I'm curious what's breaking when we invoke bin/jruby
.
@postmodern Just tried this and I can no longer reproduce it. Closing.
Actually, got it! It happens when switching from another ruby in the apps folder containing the .jrubyrc
file.
LoadError: no such file to load -- bundler/setup
require at org/jruby/RubyKernel.java:939
require at /Users/deivid/.rubies/jruby-9.0.4.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:54
<top> at file:/Users/deivid/.rubies/jruby-9.0.4.0/lib/jruby.jar!/jruby/bundler/startup.rb:4
@deivid-rodriguez guessing the exception is happening during jruby startup, and not from the code we pipe into the ruby. Is this a chicken and egg problem, where we need to gem install bundler
under jruby, but can't invoke bin/jruby
because the lack of bundler? Ideally, jruby should print a warning and keep executing.
But bundler
is installed... After commenting out the .jrubyrc
:
$ chruby ruby
$ chruby
* jruby-9.0.4.0
ruby-2.0.0-p648
ruby-2.1.8
ruby-2.2.4
ruby-2.3.0-preview2
$ bundle --version
Bundler version 1.11.2
That's because when chruby first invokes jruby, GEM_HOME
isn't set so jruby can't find bundler.
chruby
fails injruby
with a project containing a.jrubyrc
file with thecli.load.gemfile=true
configuration.