From 0cad38b82ae7d80fd507251f646d86e27c866f39 Mon Sep 17 00:00:00 2001 From: Jiahao XU <30436523+NobodyXu@users.noreply.github.com> Date: Sat, 9 Nov 2024 15:33:43 +1100 Subject: [PATCH] Fi install-from-binstall-release.ps1 Signed-off-by: Jiahao XU <30436523+NobodyXu@users.noreply.github.com> --- install-from-binstall-release.ps1 | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/install-from-binstall-release.ps1 b/install-from-binstall-release.ps1 index d9f33515..c3875912 100644 --- a/install-from-binstall-release.ps1 +++ b/install-from-binstall-release.ps1 @@ -20,9 +20,8 @@ Invoke-WebRequest $url -OutFile $tmpdir\cargo-binstall.zip Expand-Archive -Force $tmpdir\cargo-binstall.zip $tmpdir\cargo-binstall Write-Host "" -Try { - Invoke-Expression "$tmpdir\cargo-binstall\cargo-binstall.exe --self-install" -} Catch { +$ps = Start-Process -PassThru -Wait "$tmpdir\cargo-binstall\cargo-binstall.exe" "--self-install" +if ($ps.ExitCode -eq 0) { Invoke-Expression "$tmpdir\cargo-binstall\cargo-binstall.exe -y --force cargo-binstall" }