Mar*_*cie 5 yaml azure-devops azure-pipelines-yaml
trigger:
- develop
pool:
vmImage: windows-2019
- task: MSBuild@1
inputs:
solution: '**/*.sln'
- task: DownloadBuildArtifacts@1
inputs:
buildType: 'current'
downloadType: 'single'
itemPattern: '**/*.exe'
downloadPath: '$(System.ArtifactsDirectory)'
Run Code Online (Sandbox Code Playgroud)
我在 Azure DevOps 和使用 VS Code 的 YAML 扩展中遇到此 YAML 错误。我正在尝试构建一个 Windows 服务,然后将 .exe 文件放在我可以下载的地方。
Azure 开发运营:
VS代码

错误:
隐式键需要位于一行上,隐式映射键需要后跟映射值
尽管该错误看起来有些令人困惑,但您缺少关键字steps。
trigger:
- develop
pool:
vmImage: windows-2019
steps:
- task: MSBuild@1
inputs:
solution: '**/*.sln'
- task: DownloadBuildArtifacts@1
inputs:
buildType: 'current'
downloadType: 'single'
itemPattern: '**/*.exe'
downloadPath: '$(System.ArtifactsDirectory)'
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
19746 次 |
| 最近记录: |