Fix process name
This commit is contained in:
@@ -4,7 +4,11 @@ Param (
|
||||
[String] $Version,
|
||||
[Parameter(Mandatory = $false)]
|
||||
[ValidateSet("amd64", "arm64")]
|
||||
[String] $Arch = "amd64"
|
||||
[String] $Arch = "amd64",
|
||||
[Parameter(ParameterSetName='Signing', Mandatory = $false)]
|
||||
[Switch] $Sign = $false,
|
||||
[Parameter(ParameterSetName='Signing', Mandatory = $false)]
|
||||
[String] $CertificateThumbprint
|
||||
)
|
||||
$ErrorActionPreference = "Stop"
|
||||
|
||||
@@ -18,6 +22,13 @@ Trap {
|
||||
Pop-Location
|
||||
}
|
||||
|
||||
$cert=Get-ChildItem Cert:\CurrentUser\My -CodeSigningCert | Where-Object { $_.Thumbprint -eq $CertificateThumbprint }
|
||||
Get-ChildItem -Path '..\src' | Where-Object {$_.Extension -eq '.ps1'} | ForEach-Object {
|
||||
Copy-Item -Path $_.FullName -Destination "..\engine" -Force
|
||||
if ($Sign) {
|
||||
Set-AuthenticodeSignature -FilePath "..\engine\$($_.Name)" -TimestampServer 'http://time.certum.pl' -Certificate $cert
|
||||
}
|
||||
}
|
||||
|
||||
Write-Verbose "Creating winbgp-${Version}-${Arch}.msi"
|
||||
$wixArch = @{"amd64" = "x64"; "arm64" = "arm64"}[$Arch]
|
||||
@@ -26,3 +37,9 @@ Invoke-Expression "wix build -arch $wixArch -o .\WinBGP-$($Version)-$($Arch).msi
|
||||
|
||||
Write-Verbose "Done!"
|
||||
Pop-Location
|
||||
|
||||
Copy-Item -Path "WinBGP-$($Version)-$($Arch).msi" -Destination "..\release" -Force
|
||||
if ($Sign) {
|
||||
& "C:\Program Files (x86)\Windows Kits\10\bin\10.0.26100.0\x64\signtool.exe" sign /sha1 $CertificateThumbprint /tr http://time.certum.pl/ /td sha256 /fd sha256 /v "..\release\WinBGP-$($Version)-$($Arch).msi"
|
||||
}
|
||||
|
||||
|
||||
@@ -167,13 +167,13 @@
|
||||
<StandardDirectory Id="ProgramFiles64Folder">
|
||||
<Directory Id="APPLICATIONFOLDER" Name="WinBGP">
|
||||
<Component Id="winbgp_engine" Guid="a7b5748a-16c9-4594-85ad-de032fb3f39c">
|
||||
<File Id="winbgp_engine" Source="..\src\WinBGP-Engine.ps1" KeyPath="yes" Vital="yes" Checksum="yes" />
|
||||
<File Id="winbgp_engine" Source="..\engine\WinBGP-Engine.ps1" KeyPath="yes" Vital="yes" Checksum="yes" />
|
||||
</Component>
|
||||
<Component Id="winbgp_healthcheck" Guid="8a356315-8307-4508-b19d-00eb05e59428">
|
||||
<File Id="winbgp_healthcheck" Source="..\src\WinBGP-HealthCheck.ps1" KeyPath="yes" Vital="yes" Checksum="yes" />
|
||||
<File Id="winbgp_healthcheck" Source="..\engine\WinBGP-HealthCheck.ps1" KeyPath="yes" Vital="yes" Checksum="yes" />
|
||||
</Component>
|
||||
<Component Id="winbgp_api" Guid="77de0ab1-0e53-4967-9469-142f49b397a4">
|
||||
<File Id="winbgp_api" Source="..\src\WinBGP-API.ps1" KeyPath="yes" Vital="yes" Checksum="yes" />
|
||||
<File Id="winbgp_api" Source="..\engine\WinBGP-API.ps1" KeyPath="yes" Vital="yes" Checksum="yes" />
|
||||
</Component>
|
||||
<Component Id="winbgp_config" Guid="03063c39-1063-4126-b974-5cad888d5804" NeverOverwrite="yes" Permanent="yes" >
|
||||
<File Id="winbgp_config" Name="winbgp.json" Source="..\src\winbgp.json.example" KeyPath="yes" Checksum="yes" />
|
||||
@@ -182,7 +182,7 @@
|
||||
<File Id="winbgp_config_example" Source="..\src\winbgp.json.example" KeyPath="yes" Checksum="yes" />
|
||||
</Component>
|
||||
<Component Id="winbgp_cli" Guid="b74d4be4-3de4-4006-a271-b56d078d2bcc">
|
||||
<File Id="winbgp_cli" Source="..\src\WinBGP.ps1" KeyPath="yes" Vital="yes" Checksum="yes" />
|
||||
<File Id="winbgp_cli" Source="..\engine\WinBGP.ps1" KeyPath="yes" Vital="yes" Checksum="yes" />
|
||||
</Component>
|
||||
</Directory>
|
||||
</StandardDirectory>
|
||||
|
||||
Reference in New Issue
Block a user