0

Because of this question I tried to change my Azure Devops build process to use DotNet isntead of Nuget

The task is now

- task: DotNetCoreCLI@2
  inputs:
    command: pack
    packagesToPack: '**/SBD.*.csproj'
    versioningScheme: byPrereleaseNumber
    majorVersion: '$(Major)'
    minorVersion: '$(Minor)'
    patchVersion: '$(Patch)

And the error is

error MSB4057: The target "pack" does not exist in the project

I found this question but it is not for DevOps

The answer mentions I need to install the Nuget.Build.Tasks Pack package from Nuget

So I did that

Now the log in devops states

C:\Users\VssAdministrator\.nuget\packages\nuget.build.tasks.pack\5.6.0\build\NuGet.Build.Tasks.Pack.targets(198,5): 
error : Authors is required. [D:\a\1\s\Common.WinForms\SBD.Common.WinForms.csproj]
Kirsten Greed
  • 11,170
  • 26
  • 117
  • 234

1 Answers1

1

The failing project was net472. I should not use DotNetCoreCli to pack it

Kirsten Greed
  • 11,170
  • 26
  • 117
  • 234
  • Thanks for sharing your solution here, would you please accept your solution as the answer? So it would be helpful for other members who get the same issue to find the solution easily. Have a nice day:) – Hugh Lin - MSFT Jun 15 '20 at 07:36