title: Rails is not using my global Ruby version
body: <p>I want to use Rails with Ruby 2.1.0, but it's using Ruby 1.9.3 (the system's version).</p>
  
  <p>I'm using <a href="https://github.com/sstephenson/rbenv" rel="noreferrer">rbenv</a> to manage my Ruby versions. My steps were something along the lines of:</p>
  
  <pre><code>$ rbenv install 2.1.0
  $ rbenv global 2.1.0
  $ sudo gem install rails -v 4.0.2
  $ rbenv rehash
  $ rbenv versions
    system
  * 2.1.0 (set by /home/dennis/.rbenv/version)
  $ ruby -v
  ruby 2.1.0p0 (2013-12-25 revision 44422) [x86_64-linux]
  $ rails new app &amp;&amp; cd app
  $ rails server
  </code></pre>
  
  <p>Rails is using is Ruby 1.9.3 (x86_64-linux), according to <code>localhost:3000/rails/info/properties</code>. A log message from <code>rails server</code> gives: <code>INFO  ruby 1.9.3 (2012-04-20) [x86_64-linux]</code>.</p>
  
  <p>I think Rails is using the system version of Ruby because the versions match.</p>
  
  <pre><code>$ rbenv local system
  $ ruby -v
  ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux]
  $ rbenv local --unset  # Unset local Ruby version, go back to 2.1.0
  </code></pre>
  
  <p>Some things I've tried with no luck:</p>
  
  <ul>
  <li>setting the local and shell versions of Ruby to 2.1.0 with rbenv</li>
  <li>rehash rbenv shims (rbenv says to do this  after installing executables)</li>
  <li>made new Rails projects after switching to 2.1.0 just in case I made the projects while using 1.9.3</li>
  <li>putting <code>2.1.0</code> in a <code>.ruby-version</code> file in the root of my project (suggested by @Agis)</li>
  <li>restarting terminal session and starting a login bash shell (suggested by @Russel)</li>
  <li>specifying the desired Ruby version in the project's Gemfile (suggested by @rlecaro2)</li>
  </ul>
  
  <p>FWIW, I'm using Ubuntu 13.10 with the fish shell.</p>