fix: safesightd.ps1 显式指定windows/amd64平台
This commit is contained in:
parent
8f7467bb63
commit
b369cfd81a
@ -82,10 +82,12 @@ function Show-Health {
|
||||
}
|
||||
|
||||
function Invoke-Build {
|
||||
Write-Info "编译 safesightd.exe ..."
|
||||
Write-Info "编译 safesightd.exe (windows/amd64) ..."
|
||||
Push-Location $rootDir
|
||||
try {
|
||||
& go build -o $exePath .\cmd\safesightd
|
||||
$env:GOOS = "windows"
|
||||
$env:GOARCH = "amd64"
|
||||
& go build -ldflags="-s -w" -o $exePath .\cmd\safesightd
|
||||
if ($LASTEXITCODE -ne 0) {
|
||||
throw "go build failed with exit code $LASTEXITCODE"
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user