diff --git a/scripts/download.ps1 b/scripts/download.ps1 index 733a6444..86ff6d50 100644 --- a/scripts/download.ps1 +++ b/scripts/download.ps1 @@ -31,8 +31,11 @@ Remove-Item -Force data.zip Remove-Item -Force mode.zip Remove-Item -Force i18n.zip -..\scripts\download\cloak.ps1 -OutputPath Bin -..\scripts\download\xray-core.ps1 -OutputPath Bin +..\scripts\download\cloak.ps1 -OutputPath Bin +..\scripts\download\geoip.ps1 -OutputPath Bin +..\scripts\download\geosite.ps1 -OutputPath Bin +..\scripts\download\v2ray-core.ps1 -OutputPath Bin +..\scripts\download\x2ray-core.ps1 -OutputPath Bin Get-Item * Set-Location $last diff --git a/scripts/download/geoip.ps1 b/scripts/download/geoip.ps1 new file mode 100644 index 00000000..38add4d2 --- /dev/null +++ b/scripts/download/geoip.ps1 @@ -0,0 +1,7 @@ +param([string]$OutputPath) +$address="https://github.com/v2fly/geoip/releases/download/202107080024/geoip.dat" + +Invoke-WebRequest -Uri $address -OutFile geoip.dat + +Move-Item -Force geoip.dat $OutputPath +exit 0 \ No newline at end of file diff --git a/scripts/download/geosite.ps1 b/scripts/download/geosite.ps1 new file mode 100644 index 00000000..9ddcbf2e --- /dev/null +++ b/scripts/download/geosite.ps1 @@ -0,0 +1,7 @@ +param([string]$OutputPath) +$address="https://github.com/v2fly/domain-list-community/releases/download/20210709152606/dlc.dat" + +Invoke-WebRequest -Uri $address -OutFile geosite.dat + +Move-Item -Force geosite.dat $OutputPath +exit 0 \ No newline at end of file diff --git a/scripts/download/v2ray-core.ps1 b/scripts/download/v2ray-core.ps1 new file mode 100644 index 00000000..17fb8d6b --- /dev/null +++ b/scripts/download/v2ray-core.ps1 @@ -0,0 +1,13 @@ +param([string]$OutputPath) +$address="https://github.com/v2fly/v2ray-core/releases/download/v4.40.1/v2ray-windows-64.zip" + +Invoke-WebRequest -Uri $address -OutFile v2ray-core.zip +Expand-Archive -Force -Path v2ray-core.zip -DestinationPath v2ray-core + +Move-Item -Force v2ray-core\v2ctl.exe $OutputPath +Move-Item -Force v2ray-core\v2ray.exe $OutputPath +Move-Item -Force v2ray-core\wv2ray.exe $OutputPath + +Remove-Item -Recurse -Force v2ray-core +Remove-Item -Recurse -Force v2ray-core.zip +exit 0 \ No newline at end of file diff --git a/scripts/download/xray-core.ps1 b/scripts/download/x2ray-core.ps1 similarity index 66% rename from scripts/download/xray-core.ps1 rename to scripts/download/x2ray-core.ps1 index a8ebb728..ef20113d 100644 --- a/scripts/download/xray-core.ps1 +++ b/scripts/download/x2ray-core.ps1 @@ -4,9 +4,7 @@ $address="https://github.com/XTLS/Xray-core/releases/download/v1.4.2/Xray-window Invoke-WebRequest -Uri $address -OutFile xray-core.zip Expand-Archive -Force -Path xray-core.zip -DestinationPath xray-core -Move-Item -Force xray-core\xray.exe $OutputPath -Move-Item -Force xray-core\geoip.dat $OutputPath -Move-Item -Force xray-core\geosite.dat $OutputPath +Move-Item -Force xray-core\xray.exe $OutputPath Remove-Item -Recurse -Force xray-core Remove-Item -Recurse -Force xray-core.zip