How to include nuget packages in a project to make the project portable

拈花ヽ惹草 提交于 2020-01-24 01:08:05

问题


According to this, I decided to use nuget in the project. I would like to make it "portable" - add the used packages in the git repository and requiering no internet connection on the server side. What is the way to do it?


回答1:


You should add path to the local copy of the repository, your NuGet location to the Options -> NuGet Package Manager -> Package Sources and install the NuGet from this location instead of installing it from the server or anywhere else.

Having the location of your NuGet files inside the NuGet.config file which is used by Visual Studio when building the project, will download the needed packages from the specified location.



来源:https://stackoverflow.com/questions/59369847/how-to-include-nuget-packages-in-a-project-to-make-the-project-portable

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