mirror of
https://github.com/house-of-vanity/v2-uri-parser.git
synced 2025-12-15 14:47:51 +00:00
Silently continue on Remove-Item errors
This commit is contained in:
committed by
GitHub
parent
e1aca3b282
commit
6e4a5da563
@@ -22,7 +22,7 @@ $v2asset = $v2release.assets | Where-Object { $_.name -eq "v2parser-x86_64-pc-wi
|
|||||||
$v2zip = "$env:TEMP\v2parser.zip"
|
$v2zip = "$env:TEMP\v2parser.zip"
|
||||||
Invoke-WebRequest -Uri $v2asset.browser_download_url -OutFile $v2zip
|
Invoke-WebRequest -Uri $v2asset.browser_download_url -OutFile $v2zip
|
||||||
Expand-Archive -Path $v2zip -DestinationPath $binPath -Force
|
Expand-Archive -Path $v2zip -DestinationPath $binPath -Force
|
||||||
Remove-Item $v2zip
|
Remove-Item $v2zip -ErrorAction SilentlyContinue
|
||||||
|
|
||||||
# Download Xray-core
|
# Download Xray-core
|
||||||
$xrayRepo = "XTLS/Xray-core"
|
$xrayRepo = "XTLS/Xray-core"
|
||||||
@@ -31,7 +31,7 @@ $xrayAsset = $xrayRelease.assets | Where-Object { $_.name -eq "Xray-windows-64.z
|
|||||||
$xrayZip = "$env:TEMP\xray.zip"
|
$xrayZip = "$env:TEMP\xray.zip"
|
||||||
Invoke-WebRequest -Uri $xrayAsset.browser_download_url -OutFile $xrayZip
|
Invoke-WebRequest -Uri $xrayAsset.browser_download_url -OutFile $xrayZip
|
||||||
Expand-Archive -Path $xrayZip -DestinationPath $binPath -Force
|
Expand-Archive -Path $xrayZip -DestinationPath $binPath -Force
|
||||||
Remove-Item $xrayZip
|
Remove-Item $xrayZip -ErrorAction SilentlyContinue
|
||||||
|
|
||||||
# Request server location
|
# Request server location
|
||||||
$serverLocation = Read-Host "Enter server location (e.g., US-NY, DE-Berlin, JP-Tokyo)"
|
$serverLocation = Read-Host "Enter server location (e.g., US-NY, DE-Berlin, JP-Tokyo)"
|
||||||
|
|||||||
Reference in New Issue
Block a user