使用 Azure DevOps git Rest 服务端点检索分支的所有更改文件

问题描述 投票:0回答:0

我们的 Azure 构建管道需要知道分支上哪些解决方案已更改,以便它可以构建更改的解决方案。我们将每个解决方案保存在根目录之外的子目录中。

我们当前使用以下 PowerShell 来检索分支的更改,但如果稍后进行了提交,则它仅返回最后一次提交中的更改,而不是所有提交。

$url="$(System.CollectionUri)/$(System.TeamProject)/_apis/git/repositories/$(Build.Repository.ID)/commits?api-version=5.1"

所以如果我们的承诺是:

Commit1 - 服务

github azure-devops azure-pipelines
© www.soinside.com 2019 - 2024. All rights reserved.