Skip to content

Commit

Permalink
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion tool/jt.rb
Original file line number Diff line number Diff line change
@@ -144,10 +144,15 @@ def self.find_repo(name)
end

def self.find_gem(name)
["#{JRUBY_DIR}/lib/ruby/gems/shared/gems", JRUBY_DIR, "#{JRUBY_DIR}/.."].each do |dir|
["#{JRUBY_DIR}/lib/ruby/gems/shared/gems"].each do |dir|
found = Dir.glob("#{dir}/#{name}*").first
return found if found
end

[JRUBY_DIR, "#{JRUBY_DIR}/.."].each do |dir|
found = Dir.glob("#{dir}/#{name}").first
return found if found
end
raise "Can't find the #{name} gem - gem install it in this repository, or put it in the repository directory or its parent"
end

0 comments on commit 04e8160

Please sign in to comment.