Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Nuget cache in linux

I am testing Asp.net 5 (vnext) in Linux Ubuntu 14.04.3 LTS and I would like to know where is located Nuget cache to properly set local repository in Nuget.Config. Anyone know?

like image 879
Donald Avatar asked Jul 10 '26 05:07

Donald


2 Answers

The global-packages folder is where NuGet installs any downloaded package. Each package is fully expanded into a subfolder that matches the package identifier and version number. Projects using the PackageReference format always use packages directly from this folder. When using the packages.config, packages are installed to the global-packages folder, then copied into the project's packages folder.

  • Windows: %userprofile%\.nuget\packages
  • Mac/Linux: ~/.nuget/packages

You can also view global-packages location using below command

dotnet nuget locals global-packages --list

Typical output (Mac/Linux; "user1" is the current username):

info : global-packages: /home/user1/.nuget/packages/

For all folders used by NuGet to manages packages and package information use below command

dotnet nuget locals all --list

For more details

like image 81
ElasticCode Avatar answered Jul 11 '26 21:07

ElasticCode


NuGet cache is typically located in ~/.local/share/NuGet/Cache while dnu cache is located in ~/.local/share/dnu/cache.

like image 37
Pawel Avatar answered Jul 11 '26 21:07

Pawel



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!