title: Mystery: Rails installed but not detected -- RVM 2.1.5 fixes it
body: <p>When I run:</p>
  
  <pre><code>$ rails -v
  </code></pre>
  
  <p>I get:</p>
  
  <pre><code>Rails 4.1.8
  </code></pre>
  
  <p>Which means Rails is installed right? However whenever I cd into my app's directory and run Rails, I get:</p>
  
  <pre><code>Rails is not currently installed on this system. To get the latest version, simply type:
  
  $ sudo gem install rails
  </code></pre>
  
  <p>I found the solution below but really wanted to understand why:</p>
  
  <pre><code>$ rvm use ruby-2.1.5
  $ gem install nokogiri -- --use-system-libraries
  </code></pre>
  
  <p>Anyone know? Really appreciate your help!</p>