Nuget不重新安装软件包 [英] Nuget not reinstalling packages

查看:54
本文介绍了Nuget不重新安装软件包的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已将目标 .net 框架修改为使用 4.0 中的 4.5.我从 nuget 收到一条消息,需要重新安装软件包,因此运行 Update-Package -Reinstall -ProjectName https://localhost/SomeWebProject/.在 nuget 执行时,它会吐出如下所示的黄色警告标志:

I have modified the target .net framework to use 4.5 from 4.0. I got a message from nuget that packages need to re-installed so ran Update-Package -Reinstall -ProjectName https://localhost/SomeWebProject/. As nuget was executing, it spitted out yellow warning signs that looked like this:

Skipped reinstalling package 'NLog 3.1.0.0' in project 'SomeWebProject' because the package does not exist in the package source.

为什么我的包没有被重新安装?我进入了我的包文件夹并验证了 NLog 3.1.0.0 存在!

Why aren't my packages being reinstalled? I went into my packages folder and verified NLog 3.1.0.0 exist!

推荐答案

事实证明,解决方案隐藏在显眼的位置.

Turns out the solution is hiding in plain sight.

我们所要做的就是在包管理器控制台窗口中设置包源.(感谢 Matt Ward 指出这一点.)

All we have to do is set the Package Source in the Package Manager Console window. (Credits to Matt Ward for pointing it out.)

这篇关于Nuget不重新安装软件包的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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