diff --git a/tools/releaseBuild/azureDevOps/templates/windows-packaging.yml b/tools/releaseBuild/azureDevOps/templates/windows-packaging.yml index 4987514291fb..7a16c2bc678c 100644 --- a/tools/releaseBuild/azureDevOps/templates/windows-packaging.yml +++ b/tools/releaseBuild/azureDevOps/templates/windows-packaging.yml @@ -178,7 +178,14 @@ jobs: $null = New-Item -ItemType Directory -Path $signedFilesDirectory -Force $missingSignatures | ForEach-Object { - Copy-Item -Path $_ -Destination $filesToSignDirectory + $pathWithoutLeaf = Split-Path $_ + $relativePath = $pathWithoutLeaf.replace($BuildPath,'') + $targetDirectory = Join-Path -Path $filesToSignDirectory -ChildPath $relativePath + if(!(Test-Path $targetDirectory)) + { + $null = New-Item -ItemType Directory -Path $targetDirectory -Force + } + Copy-Item -Path $_ -Destination $targetDirectory } displayName: Create ThirdParty Signing Folder