Browse Source

Fix: BuildToNuGetCache target should not open duplicate file handles (#21745)

pull/21750/head
Isabelle Santin 3 months ago
committed by GitHub
parent
commit
4862e605f1
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 3
      nukebuild/Build.cs

3
nukebuild/Build.cs

@ -456,9 +456,10 @@ partial class Build : NukeBuild
foreach (var path in Parameters.NugetRoot.GlobFiles("*.nupkg"))
{
var packageId = SbomGenerator.ReadPackageId(path);
using var f = File.Open(path.ToString(), FileMode.Open, FileAccess.Read);
using var zip = new ZipArchive(f, ZipArchiveMode.Read);
var packageId = SbomGenerator.ReadPackageId(path);
var packagePath = Path.Combine(
globalPackagesFolder,

Loading…
Cancel
Save