title: Ruby script cannot locate required gem
body: <p>I'm trying to run a Ruby script that has worked fine in the past. I need to use the Mechanize gem, so at the top of the script, it says <code>require 'mechanize'</code>. However, when I try to run the script now, the Terminal output reads:</p>
  
  <pre><code>/Users/codebiker/.rvm/rubies/ruby-2.1.0/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- mechanize (LoadError)
  from /Users/codebiker/.rvm/rubies/ruby-2.1.0/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
  from myscript.rb:2:in `&lt;main&gt;'
  </code></pre>
  
  <p>When I run <code>gem env</code>, as suggested here, I get:</p>
  
  <pre><code>RubyGems Environment:
    - RUBYGEMS VERSION: 2.2.1
    - RUBY VERSION: 2.1.0 (2013-12-25 patchlevel 0) [x86_64-darwin13.0]
    - INSTALLATION DIRECTORY: /Users/codebiker/.rvm/gems/ruby-2.1.0
    - RUBY EXECUTABLE: /Users/codebiker/.rvm/rubies/ruby-2.1.0/bin/ruby
    - EXECUTABLE DIRECTORY: /Users/codebiker/.rvm/gems/ruby-2.1.0/bin
    - SPEC CACHE DIRECTORY: /Users/codebiker/.gem/specs
    - RUBYGEMS PLATFORMS:
      - ruby
      - x86_64-darwin-13
    - GEM PATHS:
       - /Users/codebiker/.rvm/gems/ruby-2.1.0
       - /Users/codebiker/.rvm/gems/ruby-2.1.0@global
    - GEM CONFIGURATION:
       - :update_sources =&gt; true
       - :verbose =&gt; true
       - :backtrace =&gt; false
       - :bulk_threshold =&gt; 1000
       - :benchmark =&gt; false
       - :sources =&gt; ["http://rubygems.org/", "http://gemcutter.org"]
       - "install" =&gt; "--no-rdoc --no-ri"
       - "update" =&gt; "--no-rdoc --no-ri"
    - REMOTE SOURCES:
       - http://rubygems.org/
       - http://gemcutter.org
    - SHELL PATH:
       - /Users/codebiker/.rvm/gems/ruby-2.1.0/bin
       - /Users/codebiker/.rvm/gems/ruby-2.1.0@global/bin
       - /Users/codebiker/.rvm/rubies/ruby-2.1.0/bin
       - /usr/local/bin
       - /usr/bin
       - /bin
       - /usr/sbin
       - /sbin
       - /usr/local/bin
       - /opt/X11/bin
       - /usr/texbin
       - /Users/codebiker/.rvm/bin
  </code></pre>
  
  <p>When I run <code>rvm get head</code>, I get:</p>
  
  <pre><code>Upgrading the RVM installation in /Users/codebiker/.rvm/
  RVM PATH line found in /Users/codebiker/.bashrc /Users/codebiker/.zshrc.
  RVM sourcing line found in /Users/codebiker/.bash_profile /Users/codebiker/.zprofile.
  Upgrade of RVM in /Users/codebiker/.rvm/ is complete.
  </code></pre>
  
  <p>When I run <code>which ruby</code>, I get:</p>
  
  <p><code>/Users/codebiker/.rvm/rubies/ruby-2.1.0/bin/ruby</code></p>
  
  <p>And <code>ruby -v</code> gives me:</p>
  
  <p><code>ruby 2.1.0p0 (2013-12-25 revision 44422) [x86_64-darwin13.0]</code></p>
  
  <p>Any advice, thoughts, or tips would be appreciated! I have no idea what's wrong here. </p>