我们正在寻找一种自动化方法,为来自 Azure devops 服务器发布管道(以 yaml 形式)的每个产品版本创建发行说明,以将发行说明详细信息更新到中央 wiki 和托管存储库的应用程序代码。
我使用扩展生成发行说明(跨平台)来创建发行说明文件。然后我可以将代码推送回存储库并将代码发布为 wiki。
步骤:
release-notes-template.md
文件,扩展名为 samples。XplatGenerateReleaseNotes@4
添加到您的管道以创建发行说明文件。我的测试yaml:
steps:
- checkout: self
persistCredentials: true
- task: XplatGenerateReleaseNotes@4
inputs:
outputfile: 'releasenotes.md'
templateLocation: 'File'
templatefile: 'template/release-notes-template.md'
dumpPayloadToConsole: false
dumpPayloadToFile: false
replaceFile: true
getParentsAndChildren: false
getAllParents: false
getIndirectPullRequests: false
stopOnError: false
considerPartiallySuccessfulReleases: false
checkForManuallyLinkedWI: false
wiqlFromTarget: 'WorkItems'
- task: CmdLine@2
inputs:
script: |
git config --global user.email "[email protected]"
git config --global user.name "Your Name"
git add --all
git commit -m "update release note"
git push origin HEAD:main
我的结果: