diff --git a/release-tool.ps1 b/release-tool.ps1 index fda7ff891..640742adb 100644 --- a/release-tool.ps1 +++ b/release-tool.ps1 @@ -231,7 +231,9 @@ function Invoke-GpgSignFiles([string[]] $files, [string] $key) { foreach ($_ in $files) { Write-Host "Signing file '$_' and creating DIGEST..." - Remove-Item "$_.sig" + if (Test-Path "$_.sig") { + Remove-Item "$_.sig" + } Invoke-Cmd "gpg" "--output `"$_.sig`" --armor --local-user `"$key`" --detach-sig `"$_`"" $FileName = (Get-Item $_).Name (Get-FileHash "$_" SHA256).Hash + " *$FileName" | Out-File "$_.DIGEST" -NoNewline