【发布时间】:2022-10-05 17:42:37
【问题描述】:
我们有几个项目的解决方案。我们只希望将其中的 2 个项目发布到工件上。理想情况下,我们可以通过更改项目中的设置来管理它,因此管道可以是通用的。我们一直在寻找(试错)管道方面或项目方面的可能解决方案。他们都没有工作,或者没有项目最终成为工件或全部。有什么建议么 ?
#Build and distribute nnn.Core NuGets to nnnNugets artifacts feed
name: $(Year:yyyy).$(Month).$(DayOfMonth)$(Rev:.r)
variables:
feedName : \'nnnNugets\'
buildConfiguration: \'debug\'
trigger:
- nugetify
pool:
vmImage: windows-latest
steps:
- task: DotNetCoreCLI@2
displayName: \'Build\'
inputs:
command: \'build\'
projects: \'**/*.csproj\'
arguments: \'--configuration $(buildConfiguration)\'
- task: DotNetCoreCLI@2
displayName: \'Pack\'
inputs:
command: pack
versioningScheme: byBuildNumber
- task: NuGetAuthenticate@1
displayName: \'NuGet Authenticate\'
- task: NuGetCommand@2
displayName: \'NuGet push\'
inputs:
command: push
publishVstsFeed: \'$(feedName)\'
allowPackageConflicts: true
- task: PublishSymbols@2
inputs:
searchPattern: \'**/bin/**/*.pdb\'
publishSymbols: true
symbolServerType: \'teamServices\'
SymbolExpirationInDays: 1000
IndexableFileFormats: Pdb
标签: azure-devops azure-pipelines nuget-package azure-pipelines-yaml azure-artifacts