From 6834f57ba0f1fc093446acefec59a11f71997bfe Mon Sep 17 00:00:00 2001 From: matz Date: Fri, 3 Mar 2006 17:39:28 +0000 Subject: * lib/rdoc/ri/ri_paths.rb (RI::Paths): adding paths from rubygems directories. a patch from Eric Hodel . [ruby-core:07423] * eval.c (rb_thread_fd_writable): should not re-schedule output from KILLED thread (must be error printing). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10020 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/rdoc/ri/ri_paths.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'lib') diff --git a/lib/rdoc/ri/ri_paths.rb b/lib/rdoc/ri/ri_paths.rb index 32c2542c04..07d900238f 100644 --- a/lib/rdoc/ri/ri_paths.rb +++ b/lib/rdoc/ri/ri_paths.rb @@ -47,5 +47,11 @@ module RI # This is the search path for 'ri' PATH = [ SYSDIR, SITEDIR, HOMEDIR ].find_all {|p| p && File.directory?(p)} + + begin + require 'rubygems' + Dir["#{Gem.path}/doc/*/ri"].each { |path| RI::Paths::PATH << path } + rescue LoadError + end end end -- cgit v1.2.3