繁体   English   中英

从 Visual Studio (NuGet) 连接到 Azure DevOps Artifact

[英]Connect to Azure DevOps Artifact from Visual Studio (NuGet)

我成功设置 Azure DevOps Artifacts 并将其与构建管道集成。 现在我想将 Visual Studio 2019 与这个私人提要连接起来,但我发现使它工作的唯一方法是在我的帐户上生成一个 PAT 并使用它将提要添加到我机器上的 Nuget 源中。

我还尝试了 Microsoft Artifact CredProvider,但没有成功。

有没有一种方法可以在不使用 PAT 的情况下注册源?

更新正如Levi-Lu-MSFT所建议的,就目前而言,解决方案是将 AzDevOps 帐户用作 Visual Studio 中的“Visual Studio 帐户”。 如果在我的情况下,用于 AzDevOps 的帐户与 VS 帐户不同,那么我发现使其工作的唯一方法是使用 PAT 注册 NuGet 源。

我按照以下步骤将 azure 工件馈送添加到我的视觉工作室。 而且我没有使用 PAT 来消费这些包。

Go to Tools menu-->NuGet Package Manager -->Package Manager Setting-->Package Sources-->Select the green plus in the upper-right corner and enter the name and source URL of your azure feed.

使用包

右键单击项目-->管理 nuget 包。 找到您要使用的 package。 (您可能需要在 Visual Studio 中登录您的帐户(用于登录 AzureDevOps 的帐户))。

You can also go to Tools--> NuGet Package Manager > Package Manager Console and run the Install-Package command to install the package.

请参阅文档以获取更多信息。

在 Visual Studio 中使用 NuGet 包

将 NuGet 与 Azure DevOps 服务提要一起使用

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM