Skip to content

Instantly share code, notes, and snippets.

@jeremyd
Created May 22, 2009 06:04
Show Gist options
  • Save jeremyd/115961 to your computer and use it in GitHub Desktop.
Save jeremyd/115961 to your computer and use it in GitHub Desktop.
irb(main):001:0> require 'rubygems'
=> true
irb(main):002:0> Gem.available?('sinatra')
=> false
irb(main):003:0> `gem install sinatra`
WARNING: Installing to ~/.gem since /opt/local/lib/ruby/gems/1.8 and
/opt/local/bin aren't both writable.
WARNING: You don't have /Users/jeremy/.gem/ruby/1.8/bin in your PATH,
gem executables will not run.
=> "Successfully installed sinatra-0.9.2\n1 gem installed\nInstalling ri documentation for sinatra-0.9.2...\nInstalling RDoc documentation for sinatra-0.9.2...\n"
irb(main):004:0> Gem.available?('sinatra')
=> false
irb(main):006:0> Gem.refresh
=> nil
irb(main):007:0> Gem.available?('sinatra')
=> true
irb(main):008:0> require 'sinatra'
=> true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment