Whenever a new NuGet package is installed, the NuGet package will be stored in NuGet cache location and afterwards that particular NuGet package with same version will be referred from the cache location instead of the package sources that we are configured in package manger/packages.config. If some NuGet package is updated/refreshed/patched with some additional changes with same version, it is always better to clear NuGet cache before install the updated NuGet package with same version. By performing the following steps we can clear the NuGet cache locations,
For Example:
Navigate the listed cache locations by file explorer(Windows)/finder(Mac) and remove the unrequired NuGet packages manually. |
This page will automatically be redirected to the sign-in page in 10 seconds.
Please note that on OSX the cache is in by default, is .nuget/packages in the user's home directory
Hi Jan,
Thank you for notifying us, the KB has been republished and also the details have been added.
Thanks,
Abbas K
There is an extension to clear packages from the solutions folder as well as from the cache. The extension also deletes bin and obj folders. It is available for both VS2017 and VS for Mac (7.7.2).
Check out Brute Clean in extensions.
https://marketplace.visualstudio.com/items?itemName=Sameerk.BruteClean
https://addins.monodevelop.com/Project/Index/364
More info on the Blog:
https://sameer.blog/brute-clean-a-vs-extension/