cli/script/sign.ps1
Mislav Marohnić 3e0db567e8
Rotate our Windows signing certificates (#5196)
- The certificate pfx file is now read from WINDOWS_CERT_PFX
- The password to decode the pfx is in WINDOWS_CERT_PASSWORD
- Quit reading from desktop-secrets repo
- Switch osslsigncode to take in pfx instead of individual certs
- 🔥 obsolete setup scripts
2022-02-15 17:23:39 +01:00

12 lines
445 B
PowerShell

param (
[string]$Certificate = $(throw "-Certificate is required."),
[string]$Executable = $(throw "-Executable is required.")
)
Set-StrictMode -Version Latest
$ErrorActionPreference = "Stop"
$ProgramName = "GitHub CLI"
$scriptPath = split-path -parent $MyInvocation.MyCommand.Definition
& $scriptPath\signtool.exe sign /d $ProgramName /f $Certificate /p $env:CERT_PASSWORD /fd sha256 /tr http://timestamp.digicert.com /v $Executable