rubygems - How to search for gems inside of Ruby code, or where did Gem::RemoteInstaller go? -


In Ruby Cookbook recipe 18.1, it is said that

  gem :: Remote Installer New.search ('rails')   

can search gems at remote sites, default on rubygems.org

but I have Ruby 1.8.6, 1.8 Tried .7, and 1.9.2, and all of this says

 in  `  

I have tried before

  requires' rubygems'  < / Pre> 

and even

  is required 'rubygems / remote_installer'   

What is the use of gem inside Ruby? Is there any new way?

(Please do not reply to the system like "gem list rail")

Gems: Remote installer has been removed from Rubiagam since version 1.0, it was some time ago.If you seek the ability to set someone with a gem Those who do not need, then I strongly suggest the bundler (a right, you can try:

  requires 'rubygems' R = Gem :: SpecFetcher.new r.suggest_gems_from_name ('Rail') = & Gt; ["Rail"]    

Comments