mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 03:27:05 +01:00
remove quotes from python version in bootstrap request URL (#32433)
This commit is contained in:
@@ -18,7 +18,7 @@ function ExtractVersion {
|
||||
param([string] $Path, [string] $Key)
|
||||
foreach ($Line in Get-Content $Path) {
|
||||
if ($Line.StartsWith("export $Key=")) {
|
||||
return $Line.Substring("export $Key=".Length)
|
||||
return $Line.Substring("export $Key=".Length).Trim('"')
|
||||
}
|
||||
}
|
||||
throw "Couldn't find value for $Key in $Path"
|
||||
@@ -42,10 +42,9 @@ if (!(Test-Path $PythonExe -PathType Leaf)) {
|
||||
New-Item $Cache -ItemType Directory -ErrorAction silentlyContinue | Out-Null
|
||||
|
||||
$Archive = "$Cache/python-$PythonVersion-embed.zip"
|
||||
Invoke-WebRequest `
|
||||
"https://www.python.org/ftp/python/$PythonVersion/python-$PythonVersion-embed-amd64.zip" `
|
||||
-OutFile $Archive `
|
||||
-ErrorAction Stop
|
||||
$RequestUrl = "https://www.python.org/ftp/python/$PythonVersion/python-$PythonVersion-embed-amd64.zip"
|
||||
Write-Output "Downloading from: $RequestUrl"
|
||||
Invoke-WebRequest $RequestUrl -OutFile $Archive -ErrorAction Stop
|
||||
|
||||
[System.IO.Compression.ZipFile]::ExtractToDirectory($Archive, $PythonDir)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user