[Rubygems-developers] GUI Interfacing with rubygems?

Eloy Duran eloy.de.enige at gmail.com
Thu Dec 28 07:18:22 EST 2006


I'm trying to create an Mac OS X interface to rubygems which should
be part of an RubyCocoa IDE.
I've looked at another application (rubyslippers) which has a GUI for rubygems,
but it seems to me that it just uses the 'gem' command line tool.
Which is an option, but I would prefer to be able to use some public Gem api
if available.

Right now I did some testing with the internals of rubygems like:

require 'rubygems/remote_installer'
require 'yaml'

query = 'event'
result = Gem::RemoteInstaller.new().search(query)

which returns an array of gems that have 'event' in their name,
but it doesn't for instance group them like the results shown on the
command line.
So for a gem like 'eventmachine' instead of 1 result with multiple versions
I would get multiple 'eventmachine' results for the different versions
Also it only searches based on the title of the gem, not the description...

So to wrap it up, I could of course revert to wrapping the 'gem'
command line tool,
and maybe even scraping the rubyforge.org search results page
(because it also searches on the description).
But I rather wouldn't. Could someone tell me if such an interface
exists and maybe
point me to some documentation or an example??

Kind regards,

More information about the Rubygems-developers mailing list