title: Why is bundler using an old version of ruby, and not recognizing new gems that are installed?
body: <p>In my Heroku/Sinatra app I set up my gemfile with Ruby 1.8.7 and then later used RVM to set my default to 2.0.0. Now when I try and install any new gems such Sinatra-flash or Pony, the gems aren't recognized or found when I require them in my main.rb file.</p>
  
  <p>When I add gem "pony" in my gemfile I get a popup message saying:</p>
  
  <pre><code>Gem 'pony' is not available in SDK 'ruby-1.8.7-p385' 
  </code></pre>
  
  <p>even though I've installed it. When I type <code>gem list</code> into the terminal, it returns all the gems I've installed that aren't being recognized as installed in my program.</p>
  
  <p>If I add <code>require 'sinatra/flash'</code> or <code>require 'pony'</code> in my main.rb, I get a message:</p>
  
  <pre><code>no such file to load
  </code></pre>
  
  <p>I'd really appreciate any help on this, this has been driving me nuts.</p>
  
  <p>Edited:</p>
  
  <p>Using command <code>sudo gem install 'gemname'</code></p>
  
  <p>When I enter <code>rvm info</code> I get back</p>
  
  <pre><code>ruby :
      interpreter:  "ruby"
      version:      "2.0.0p195"
      date:         "2013-05-14"
      platform:     "x86_64-darwin12.3.0"
      patchlevel:   "2013-05-14 revision 40734"
      full_version: "ruby 2.0.0p195 (2013-05-14 revision 40734) [x86_64-darwin12.3.0]"
  
    homes:
      gem:          "/Users/adam419/.rvm/gems/ruby-2.0.0-p195"
      ruby:         "/Users/adam419/.rvm/rubies/ruby-2.0.0-p195"
  
    binaries:
      ruby:         "/Users/adam419/.rvm/rubies/ruby-2.0.0-p195/bin/ruby"
      irb:          "/Users/adam419/.rvm/rubies/ruby-2.0.0-p195/bin/irb"
      gem:          "/Users/adam419/.rvm/rubies/ruby-2.0.0-p195/bin/gem"
      rake:         "/Users/adam419/.rvm/gems/ruby-2.0.0-p195@global/bin/rake"
  
    environment:
      PATH:         "/Users/adam419/.rvm/gems/ruby-2.0.0-p195/bin:/Users/adam419/.rvm/gems/ruby-2.0.0-p195@global/bin:/Users/adam419/.rvm/rubies/ruby-2.0.0-p195/bin:/Users/adam419/.rvm/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/git/bin:/usr/local/git/bin/[["
      GEM_HOME:     "/Users/adam419/.rvm/gems/ruby-2.0.0-p195"
      GEM_PATH:     "/Users/adam419/.rvm/gems/ruby-2.0.0-p195:/Users/adam419/.rvm/gems/ruby-2.0.0-p195@global"
      MY_RUBY_HOME: "/Users/adam419/.rvm/rubies/ruby-2.0.0-p195"
      IRBRC:        "/Users/adam419/.rvm/rubies/ruby-2.0.0-p195/.irbrc"
      RUBYOPT:      ""
      gemset:       ""
  </code></pre>
  
  <p>Edit: After I enter 'rvm use ruby-2.0.0' and then 'bundle install'</p>
  
  <p>I get;</p>
  
  <pre><code>Adams-MacBook-Pro:songs adam419$ rvm use ruby-2.0.0
  Using /Users/adam419/.rvm/gems/ruby-2.0.0-p195
  Adams-MacBook-Pro:songs adam419$ bundle install
  Fetching gem metadata from https://rubygems.org/.........
  Fetching gem metadata from https://rubygems.org/..
  Resolving dependencies...
  Could not find gem 'sinatra/flash (&gt;= 0) ruby' in the gems available on this machine.
  </code></pre>
  
  <p>After changing from gem "sinatra/flash" to gem "sinatra-flash" and then running bundle install</p>
  
  <pre><code>Fetching gem metadata from https://rubygems.org/.........
  Fetching gem metadata from https://rubygems.org/..
  Resolving dependencies...
  Enter your password to install the bundled RubyGems to your system: 
  Using addressable (2.2.8) 
  Installing daemons (1.1.9) 
  Using data_objects (0.10.12) 
  Using dm-core (1.2.0) 
  Using dm-do-adapter (1.2.0) 
  Installing dm-migrations (1.2.0) 
  Using do_sqlite3 (0.10.12) 
  Using dm-sqlite-adapter (1.2.0) 
  Installing eventmachine (1.0.3) 
  Using rack (1.5.2) 
  Using rack-protection (1.5.0) 
  Using sass (3.2.9) 
  Using tilt (1.4.1) 
  Using sinatra (1.4.2) 
  Using sinatra-flash (0.3.0) 
  Installing temple (0.6.5) 
  Installing slim (1.3.9) 
  Installing thin (1.5.1) 
  Using bundler (1.3.5) 
  Your bundle is complete!
  Gems in the group production were not installed.
  Use `bundle show [gemname]` to see where a bundled gem is installed.
  </code></pre>
  
  <p>Current Gemfile</p>
  
  <pre><code>source 'https://rubygems.org'
  gem "sinatra"
  gem "slim"
  gem "sass"
  gem "dm-core"
  gem "sinatra-flash"
  gem "dm-migrations"
  gem "thin"
  gem "pg", :group =&gt; :production
  gem "dm-postgres-adapter", :group =&gt; :production
  gem "dm-sqlite-adapter", :group =&gt; :development
  </code></pre>
  
  <p>Gemlock file dependencies</p>
  
  <pre><code>DEPENDENCIES
    dm-core
    dm-migrations
    dm-postgres-adapter
    dm-sqlite-adapter
    pg
    sass
    sinatra
    sinatra-flash
    slim
    thin
  </code></pre>