tag:help.appveyor.com,2012-11-13:/discussions/problems/17015-error-netsdk1004-assets-file-projectassetsjson-not-found-run-a-nuget-package-restore-to-generate-this-fileAppVeyor: Discussion 2018-11-24T21:00:30Ztag:help.appveyor.com,2012-11-13:Comment/461272162018-09-22T21:52:25Z2018-09-22T21:52:25Zerror NETSDK1004: Assets file '...\project.assets.json' not found. Run a NuGet package restore to generate this file<div><p>I believe <code>nuget restore</code> only checks current directory and since you are running it from a directory without a <em>.sln</em> file it fails.</p>
<p>Try running</p>
<pre>
<code> - nuget restore ./Kinoheld.Api.Client/Kinoheld.Api.Client.sln</code>
</pre></div>Owen McDonnelltag:help.appveyor.com,2012-11-13:Comment/461272162018-09-22T22:30:04Z2018-09-23T10:05:11Zerror NETSDK1004: Assets file '...\project.assets.json' not found. Run a NuGet package restore to generate this file<div><p>Thanks you, that works. It also works with "dotnet restore ......"<br>
Will this be obsolete in the near future? It's a bit uncomfortable to do that everytime you add a solution.</p>
<p>I don't mind this, because I will be only doing one or two solutions. But when it comes to bigger projects with alot of solutions, it might be a bit annoying.... :)</p>
<p>Edit:\</p>
<p>Another small question: Is the automatic nuget package building with a nuspec also problematic with .NET standard / core? I think I set up everything like it should be, my nuspec is at the root of the project and is named exactly like the csproj-file, but it still isn't generating a nuget package, although I checked "Package NuGet projects". :(</p>
<p>Edit 2:\<br>
So, I dont know what changed, but its working now :)</p></div>Janniktag:help.appveyor.com,2012-11-13:Comment/461272162018-09-24T06:43:29Z2018-09-24T06:43:29Zerror NETSDK1004: Assets file '...\project.assets.json' not found. Run a NuGet package restore to generate this file<div><p>For larger projects with multiple solutions you could always add the same repo as multiple projects in AppVeyor if that seems less "annoying" to you.</p>
<p>Alternatively, you could enable <a href="https://www.appveyor.com/docs/nuget/#visual-studio-nuget-restore">Visual Studio nuget restore</a></p></div>Owen McDonnell