2015-10-15 131 views
4

我喜欢在我的Visual Studio Community 2015项目中包含CommonServiceLocator.MefAdapter。 当我尝试安装软件包:https://www.nuget.org/packages/CommonServiceLocator.MefAdapter/1.0.0安装包:无法找到包'CommonServiceLocator.MefAdapter

我得到的错误:

PM> Install-Package CommonServiceLocator.MefAdapter Install-Package : Unable to find package 'CommonServiceLocator.MefAdapter' At line:1 char:17 + Install-Package <<<< CommonServiceLocator.MefAdapter + CategoryInfo : NotSpecified: (:) [Install-Package], Exception + FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand

回答

11

退房,你对的NuGet服务器的路径是正确的。

你可以这样做:Tools-> Options-> NuGet Package Manager(使用搜索)。检查你的路径是https://api.nuget.org/v3/index.json

enter image description here

我已经创建了一个项目,我就在那里安装该软件包。

4

如果您为Nuget注册了多个源代码,则在Visual Studio 2015中,可能需要从Package Manager控制台左上角的下拉列表中选择正确的源代码。

Drop down