fix(windows): make pwsh alias 'powershell ...' rather '... | powershell"

This commit is contained in:
AJ ONeal
2023-11-11 23:39:18 -07:00
parent f69d3658c7
commit 344c1d6af8
+5 -2
View File
@@ -1,5 +1,8 @@
#!/bin/pwsh
Write-Output "'pwsh@$Env:WEBI_TAG' is an alias for 'powershell@$Env:WEBI_VERSION'"
IF ($null -eq $Env:WEBI_HOST -or $Env:WEBI_HOST -eq "") { $Env:WEBI_HOST = "https://webinstall.dev" }
curl.exe -A MS -fsSL "$Env:WEBI_HOST/powershell@$Env:WEBI_VERSION" | powershell
$PwshBootUrl = "$Env:WEBI_HOST/powershell@$Env:WEBI_VERSION"
$PwshBootScript = "$HOME\.local\tmp\install-pwsh-boot.ps1"
Invoke-DownloadUrl -Force -URL $PwshBootUrl -Path $PwshBootScript
powershell -ExecutionPolicy Bypass $PwshBootScript