Pipeline task that scans a directory for *.nuspec files and updates the <dependencies> section from matching PackageReference entries in {id}.csproj (same behavior as the update-nuspec-action GitHub Action).
*.nuspec
<dependencies>
PackageReference
{id}.csproj
steps: - task: UseDotNet@2 displayName: Use .NET 8 runtime inputs: packageType: runtime version: 8.0.x - task: UpdateNuspec@1 displayName: Sync nuspec dependencies inputs: dir: '$(Build.SourcesDirectory)' dryRun: false
dir
$(Build.SourcesDirectory)
.nuspec
.csproj
dryRun
false
windows-latest
ubuntu-latest
win-x64
linux-x64
UseDotNet@2