Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where's the NuGet package location in ASP.NET Core?

I'm new to ASP.NET Core, and am trying to figure out where NuGet packages are stored on my local machine.

I've installed the following NuGet packages:

nuget dapper  nuget MicroOrm.Pocos.SqlGenerator 

I want to replace one of the DLL's with my own compiled version, but I don't know where to put it. The Dependencies folder shows nothing.

like image 459
nam vo Avatar asked Dec 01 '16 04:12

nam vo


People also ask

Where are NuGet packages installed .NET core?

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.

Where are NuGet package stored?

Figure 1: NuGet Packages are installed in the packages folder located in a solution's root directory. Simply copy the folders in the packages directory to the local NuGet package source directory you created in Step 1.

What is NuGet package in asp net core?

Put simply, a NuGet package is a single ZIP file with the . nupkg extension that contains compiled code (DLLs), other files related to that code, and a descriptive manifest that includes information like the package's version number.


1 Answers

For project.json the nuget directory is in the user profile folder (%UserProfile%\.nuget\packages)

UPDATE

From msdn

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.

When using PackageReference, the globalPackagesFolder configuration value from nuget.config is used. The default value is:

Windows: %userprofile%\.nuget\packages

Mac/Linux: ~/.nuget/packages

When using packages.config, the repositoryPath configuration value from nuget.config is used. The default value is:

$(Solutiondir)/packages

Both locations (globalPackagesFolder and repositoryPath) can be overridden using the NUGET_PACKAGES environment variable. The environment variable takes precedence over the configuration setting.

like image 180
Juan M. Elosegui Avatar answered Sep 23 '22 09:09

Juan M. Elosegui