Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
2.3k views
in Technique[技术] by (71.8m points)

Azure DevOps Promote NuGet packages to Release view

As part of an Azure DevOps pipeline, I would like to promote packages in our own NuGet feed to 'Release' view as part of the release build.

I have an application that traverses all project.assets.json files and find names and versions of packages used by the projects in the solution. This list is reduced by pattern matching on names to our own packages.

Previously I have succesfully used the BuildHttpClient from Microsoft.TeamFoundation.Build.WebApi to access information about builds and build artifacts.

What are the available tools for accessing Nuget Packages, feeds and views?

The REST API is described here: https://docs.microsoft.com/en-us/rest/api/azure/devops/artifactspackagetypes/nuget/update%20package%20versions?view=azure-devops-rest-6.0, but I would hate to implement the classes myself, if there is a library for the purpose.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

By reference to this doc: Azure DevOps Services .NET SDK API Reference, searching for any managed APIs by typing in the box, but we don’t find such library which implements this Rest API: NuGet - Update Package Versions.

You could create a new issue in the MicrosoftDocs/feedback repository on GitHub for this feedback.

And now we suggest that you directly use this Rest API to implement this.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...