title: NuGet packages and the bin folder in ASP.NET Web Pages site
body: <p>This is probably a very basic question but <strong>what's the mechanism for DLLs under the <code>packages</code> folder to get copied into the <code>bin</code> folder?</strong></p>
  
  <p>As an example, I have a solution that contains a single "project" (node) of type Web Site (i.e., no <code>csproj</code>, just file-system-based). It is a very basic static website. I want to add ASP.NET Web Pages support so I install <a href="http://www.nuget.org/packages/Microsoft.AspNet.WebPages/" rel="noreferrer">this NuGet package</a> and now there are some DLLs under the <code>packages</code> folder and my <code>web.config</code> has been updated. However, when I run the site, it shows YSOD with the error "Could not determine which version of ASP.NET Web Pages to use" which I guess is because there is no <code>bin</code> folder with DLLs in it (when I create a "Razor" site from scratch in Visual Studio, the <code>bin</code> folder is there). If I try to rebuild the solution, it fails with the same error which is compilation error (not runtime error) this time.</p>
  
  <p>What's the command or mechanism to restore the <code>bin</code> folder from the <code>packages</code> folder? I don't want to have DLLs in my source control and according to NuGet docs, it seems that this workflow is very much supported. I guess that if it were csproj-based project, there would be some MS Build action or something like that to use the DLLs from the <code>packages</code> folder but this is a website and I cannot define advanced build actions, can I?</p>