From 9e89fe3bf2bd394a4d58f4636e1e5993d64b89b9 Mon Sep 17 00:00:00 2001 From: chenxi Date: Sat, 26 Sep 2026 03:36:42 +0800 Subject: [PATCH] =?UTF-8?q?=E9=9A=94=E7=A6=BB=E9=83=A8=E7=BD=B2=E5=89=8D?= =?UTF-8?q?=E7=AB=AF=E6=9E=84=E5=BB=BA=E8=BF=9B=E7=A8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/deploy-from-workstation.ps1 | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/scripts/deploy-from-workstation.ps1 b/scripts/deploy-from-workstation.ps1 index 94fb9678..f50f6d93 100644 --- a/scripts/deploy-from-workstation.ps1 +++ b/scripts/deploy-from-workstation.ps1 @@ -326,7 +326,11 @@ try { # deploy-auth.ps1 is dot-sourced and can clear the automatic script path # variable on PowerShell Core. Restore it before invoking the build helper. $PSScriptRoot = $scriptRoot - & (Join-Path $scriptRoot 'build-frontend.ps1') + $pwshPath = (Get-Process -Id $PID).Path + if ([string]::IsNullOrWhiteSpace($pwshPath)) { + throw '无法定位当前 PowerShell 可执行文件。' + } + & $pwshPath -NoProfile -File (Join-Path $scriptRoot 'build-frontend.ps1') docker buildx inspect $BuilderName 2>$null | Out-Null if ($LASTEXITCODE -ne 0) {