scriptcs - Unable to read package

∥☆過路亽.° 提交于 2020-01-14 14:33:55

问题


I followed a blog post to get scriptcs running in just two steps. Basically, I did this:

@powershell -NoProfile -ExecutionPolicy Unrestricted -Command "iex ((New-Object Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%systemdrive%\chocolatey\bin

And then I got an error when doing this:

cinst scriptcs

Unable to read package from path 'jQuery.2.0.1.1.nupkg'.

This worked on a different machine, but it's failing on my current laptop. Any idea what I'm doing incorrectly?

EDIT

As per Damian's answer, below, I just had to delete the contents of the NuGet cache, located here:

C:\Users\userName\AppData\Local\NuGet\Cache


回答1:


This bug from the Chocolatey GitHub repo suggests that you need to clear the NuGet cache (%LocalAppData%\NuGet\Cache) and this should resolve itself.




回答2:


Please try-

  • Clean scriptcs_packages folder.
  • Clean scriptcs_packages.config file.
  • Then reinstall all packages needed .

Run scriptcs



来源:https://stackoverflow.com/questions/18661114/scriptcs-unable-to-read-package

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!