title: Jenkins - Run a NuGet package restore to generate this file
body: <p>When I build .NET Standard 2.0 Library on Jenkins build server</p>
  <pre><code>C:\Program Files\dotnet\sdk\2.1.302\Sdks\Microsoft.NET.Sdk\targets\Microsoft.PackageDependencyResolution.targets(198,5): error : Assets file 'C:\Jenkins\workspace\&lt;Project&gt;\Sources\Library\obj\project.assets.json' not found. Run a NuGet package restore to generate this file. [C:\Jenkins\workspace\&lt;Project&gt;\Sources\Library\Library.csproj]
  </code></pre>
  <p>I got an error above in build log.</p>
  <p>I searched about error and I found <a href="https://github.com/Microsoft/vsts-tasks/issues/3762" rel="noreferrer">solution</a></p>
  <p>However, when running:</p>
  <pre><code>dotnet restore &lt;Solution Name&gt;
  </code></pre>
  <p>the solution does not help me out when I clean my workspace before build starts.</p>
  <p>Therefore, I insert command before MSBuild but I failed with</p>
  <pre><code>C:\Program Files\dotnet\sdk\2.1.302\Sdks\Microsoft.NET.Sdk\targets\Microsoft.PackageDependencyResolution.targets(198,5): error : Package Microsoft.CodeAnalysis.CSharp.Workspaces, version 2.8.0 was not found. It might have been deleted since NuGet restore. Otherwise, NuGet restore might have only partially completed, which might have been due to maximum path length restrictions. [C:\Jenkins\workspace\&lt;Project&gt;\Sources\Web\Web.csproj]
  </code></pre>
  <p>According to <a href="https://github.com/Microsoft/vsts-tasks/issues/3762" rel="noreferrer">Solution reference</a>, maybe upgrade <em>Nuget Package Installer</em> could help me out. But I do not know how can I upgrade <em>Nuget Package Installer</em> by command line...</p>