将本地 Nuget 包导入 Visual Studio 解决方案 [英] Getting local Nuget Package into Visual Studio Solution

查看:54
本文介绍了将本地 Nuget 包导入 Visual Studio 解决方案的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的桌面上保存了一个 nuget 包文件 (*.nupkg).我正在尝试将其添加到我的 Visual Studio 解决方案中.有人知道怎么做吗?

I have a nuget package file (*.nupkg) saved on my Desktop. I am trying to get this into my Visual Studio solution. Does anyone know how to do this?

推荐答案

请按照以下步骤操作.

  1. 从 Visual Studio 中打开项目的解决方案资源管理器.

  1. Open solution exploler of your project from Visual Studio.

右键单击要在其中添加 nuget 包的项目.

Right click on the project in which you want add the nuget package.

选择管理 NuGet 包.

Select Manage NuGet Packages.

点击窗口右上角的设置图标.

Click on the settings icon present on the right top of the window.

点击+"并给出一个名称,添加保存在本地计算机中的 nuget 包位置.

Click on ' + ' and give a name add the nuget package location where it is saved in your local computer.

点击确定并切换包源"到你最近添加的.它可以从新添加的位置搜索包.

Click ok and switch "Package source" to your recently added one. which enables to search for the package from the newly added location.

在您的项目中搜索并引用包.

Search and reference the package in your project.

这篇关于将本地 Nuget 包导入 Visual Studio 解决方案的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆