Skip to content

Commit

Permalink
do not cleanup load path for jruby
Browse files Browse the repository at this point in the history
jruby does not add default gems explicitly to the load path and the cleaning
of the load path wipes out the default laod_path of jruby in cases where
JRUBY_HOME == GEM_HOME

fixes rubygems#4565
  • Loading branch information
mkristian committed May 11, 2016
1 parent 8d3eb4a commit 3a5b9c8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/bundler/shared_helpers.rb
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,8 @@ def set_rubylib

def clean_load_path
# handle 1.9 where system gems are always on the load path
if defined?(::Gem)
# jruby does not put any system gems explicitly on the load path
if defined?(::Gem) and not defined?(JRUBY_VERSION)
me = File.expand_path("../../", __FILE__)
me = /^#{Regexp.escape(me)}/

Expand Down

0 comments on commit 3a5b9c8

Please sign in to comment.