Recent projects need to add a dependency in NuGet, but the company's development machine is not net ...
Say that you crossing may not believe, do the development of the development machine actually no net .... (then you don't have to leave the flash.)
No way, the project needs to throw things into the VS inside, only to find ways to add the dependencies in
If there is a net, adding the dependencies inside the NuGet is very simple, and the search comes directly on the line.
To the point, it's still a matter of installing NuGet's package dependencies offline.
First of all.
https://www.nuget.org/
This is the NuGet official website, click in, then search in the box to find the installation package you need, I need to install fluentnhibernate, so search this (for example, ha).
Okay, here's the point. Note the download option for the red box on the left and the dependency option on the right, first click the Download option on the left, download it fluentnhibernate, and then click the Red box on the right.
Also note the picture below the red box, first download the file, and then jump into the dependencies, one thing to be aware of this dependency, or the installation will not succeed, cannot find the dependencies.
This time you will find no dependencies, then this package will download three files out.
This is the three files required for this project package.
then, the focus came again.
C:\Users\Alex\AppData\Local\NuGet\Cache
Find this folder (if you do not have this folder you can create a folder according to this folder structure)
Open the tool->nuget Package Manager, Package Manager settings, and locate the local path to the NuGet package cache. The following figure:
Click to browse and you will find the 3 files you just downloaded. See you Again,ha?
And then:
In the project, open the Tools->nuget Package Manager console, and enter the command:install-package fluentnhibernate , to install.
If this thing doesn't work, try this command, take the address.
Install-package Fluentnhibernate-source C:\Users\Alex\AppData\Local\NuGet\Cache\
The compiler interface will appear below this step.
Basically it compiles successfully and adds the dependency package to the project.