title: Guarantee same version of nuget packages
body: <p>We have a framework that is split up into lots of separate projects in one solution. I now want to create <em>NuGet</em> packages for each separate project, <em>but</em> guarantee that only one version of the framework can be used in one solution (possibly across several projects). </p>
  
  <p>For example, say the framework is made up of two projects:</p>
  
  <pre><code>Framework
     Framework_1
     Framework_2
  </code></pre>
  
  <p>Now when using this framework one project might reference <code>Framework_1</code>, while another project references <code>Framework_2</code>. I want to make sure that both packages have the same version (bonus points if there's an easy single-step process to upgrade to a newer version)</p>
  
  <p>I thought I would just define one solution level Framework package that all other packages depend on strictly. The problem is that <em>NuGet</em> has no problems simply installing several versions of the solution level package.</p>
  
  <p>Basically I tried the following:</p>
  
  <p>Solution-level <em>nuspec</em> file:</p>
  
  <pre><code>&lt;?xml version="1.0"?&gt;
  &lt;package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd"&gt;
    &lt;metadata&gt;
      &lt;id&gt;My.Framework&lt;/id&gt;
      &lt;version&gt;1.0.0&lt;/version&gt;
      &lt;title&gt;My.Framework&lt;/title&gt;
      &lt;authors&gt;voo&lt;/authors&gt;
      &lt;owners&gt;voo&lt;/owners&gt;
      &lt;requireLicenseAcceptance&gt;false&lt;/requireLicenseAcceptance&gt;
      &lt;description&gt;Some Framework Solution Package&lt;/description&gt;
      &lt;copyright&gt;Copyright ©  2015&lt;/copyright&gt;
    &lt;/metadata&gt;
  &lt;/package&gt;
  </code></pre>
  
  <p>And one <em>nuspec</em> package for one part:</p>
  
  <pre><code>&lt;?xml version="1.0"?&gt;
  &lt;package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd"&gt;
    &lt;metadata&gt;
      &lt;id&gt;My.Framework.BL&lt;/id&gt;
      &lt;version&gt;1.0.0&lt;/version&gt;
      &lt;title&gt;My.Framework.BL&lt;/title&gt;
      &lt;authors&gt;voo&lt;/authors&gt;
      &lt;owners&gt;voo&lt;/owners&gt;
      &lt;requireLicenseAcceptance&gt;false&lt;/requireLicenseAcceptance&gt;
      &lt;description&gt;Business Layer&lt;/description&gt;
      &lt;copyright&gt;Copyright ©  2015&lt;/copyright&gt;
      &lt;dependencies&gt; 
          &lt;dependency id="My.Framework" version="[1.0.0]"/&gt;
      &lt;/dependencies&gt;
    &lt;/metadata&gt;
  &lt;/package&gt;
  </code></pre>
  
  <p>The problem now is if I tried to install, say another <code>My.Framework.EF</code> package with version <code>1.0.1</code> and an explicit dependency on <code>My.Framework</code> 1.0.1 <code>Visual Studio</code> would just install <code>My.Framework</code> twice - once with version 1.0.0 and once with 1.0.1. </p>