title: How to install newest version of gems not mentioned in Gemfile.lock with bundler
body: <p>When I add a gem to a project's <code>Gemfile</code> for the first time, but I have installed the gem previously while working on another project, it uses the existing version of the gem, rather than the latest version of the gem available.</p>
  
  <p>For example, using bundler version 1.11.2, I added <code>gem 'rubocop'</code> to a project's <code>Gemfile</code>, and running <code>bundle install</code> resulted in it using RuboCop version 0.42.0, rather than the current (as of 21 October 2016) version of 0.44.1:</p>
  
  <pre><code>rubocop (0.42.0)
    parser (&gt;= 2.3.1.1, &lt; 3.0)
    powerpack (~&gt; 0.1)
    rainbow (&gt;= 1.99.1, &lt; 3.0)
    ruby-progressbar (~&gt; 1.7)
    unicode-display_width (~&gt; 1.0, &gt;= 1.0.1)
  </code></pre>
  
  <p>Running <code>bundle update rubocop</code> resulted in version 0.44.1 being used, without any pre-existing gems having their version changed. This indicates there weren't any constraints shopping me from using RuboCop version 0.44.1.</p>
  
  <pre><code>rubocop (0.44.1)
    parser (&gt;= 2.3.1.1, &lt; 3.0)
    powerpack (~&gt; 0.1)
    rainbow (&gt;= 1.99.1, &lt; 3.0)
    ruby-progressbar (~&gt; 1.7)
    unicode-display_width (~&gt; 1.0, &gt;= 1.0.1)
  </code></pre>
  
  <p>When running <code>bundle install</code>, how can I tell it, for gems that aren't mentioned in <code>Gemfile.lock</code>, to download the newest compatible version of the gem, rather than use an older version which happens to be available on the local machine?</p>
  
  <p>I tried looking at <a href="http://bundler.io/v1.13/man/bundle-install.1.html" rel="nofollow">http://bundler.io/v1.13/man/bundle-install.1.html</a> but nothing there seemed to be relevant.</p>