mirror of
https://github.com/SpotX-Official/SpotX.git
synced 2026-04-22 11:00:20 +10:00
Update
- Added support for premium accounts https://github.com/amd64fox/SpotX/issues/53 - Fixed some bugs when reinstalling Spotify - Added support for input parameters, for more flexible installation https://github.com/amd64fox/SpotX/issues/22
This commit is contained in:
77
Other installation scripts/Install_Rus.bat
Normal file
77
Other installation scripts/Install_Rus.bat
Normal file
@@ -0,0 +1,77 @@
|
||||
@echo off
|
||||
Setlocal EnableDelayedExpansion
|
||||
set "exec=powershell $PSVersionTable.PSVersion.major"
|
||||
for /f %%i in ('%exec%') do set ps-v=%%i 2>nul
|
||||
chcp 65001 >nul
|
||||
if %ps-v% LEQ 2 (
|
||||
echo Powershell %ps-v%не поддерживается
|
||||
@echo.
|
||||
echo Пожалуйста, прочитайте инструкцию "Устаревшие версии PowerShell" по следующей ссылке
|
||||
@echo.
|
||||
echo "https://4pda.to/forum/index.php?act=findpost&pid=104279894&anchor=outdated_versions"
|
||||
@echo.
|
||||
pause
|
||||
exit
|
||||
)
|
||||
curl -V >nul 2>&1
|
||||
if %errorlevel% EQU 9009 (
|
||||
echo Команда "Curl" отсутствует в системе
|
||||
@echo.
|
||||
echo Пожалуйста, перейдите по следующей ссылке для ручной установки "Curl"
|
||||
@echo.
|
||||
echo "http://www.confusedbycode.com/curl/#downloads"
|
||||
@echo.
|
||||
pause
|
||||
exit
|
||||
)
|
||||
for /f %%i in ('curl --write-out %%{http_code} --silent --output /dev/null --insecure https://raw.githubusercontent.com/amd64fox/SpotX/main/Install_Rus.ps1') do set STATUS_CODE=%%i 2>nul
|
||||
if %STATUS_CODE% EQU 200 (
|
||||
chcp 866 >nul
|
||||
powershell -Command "& {[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12}"; "& {(Invoke-WebRequest -UseBasicParsing 'https://raw.githubusercontent.com/amd64fox/SpotX/main/Install_Rus.ps1').Content | Invoke-Expression}"
|
||||
)
|
||||
if %STATUS_CODE% LSS 1 (
|
||||
echo Нет подключения к сети
|
||||
@echo.
|
||||
echo Попытка повторного подключения через ...
|
||||
TIMEOUT /T 5
|
||||
cls
|
||||
for /f %%i in ('curl --write-out %%{http_code} --silent --output /dev/null --insecure https://raw.githubusercontent.com/amd64fox/SpotX/main/Install_Rus.ps1') do set STATUS_CODE=%%i 2>nul
|
||||
if "!STATUS_CODE!" EQU "200 " (
|
||||
cls
|
||||
chcp 866 >nul
|
||||
powershell -Command "& {[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12}"; "& {(Invoke-WebRequest -UseBasicParsing 'https://raw.githubusercontent.com/amd64fox/SpotX/main/Install_Rus.ps1').Content | Invoke-Expression}"
|
||||
) else (
|
||||
echo Снова ошибка
|
||||
@echo.
|
||||
echo Проверьте свое интернет соединение
|
||||
@echo.
|
||||
echo Скрипт остановлен
|
||||
@echo.
|
||||
pause
|
||||
exit
|
||||
)
|
||||
)
|
||||
if %STATUS_CODE% GTR 100 if not %STATUS_CODE% EQU 200 (
|
||||
echo Не удалось подключиться к github.com
|
||||
@echo.
|
||||
echo Код ответа HTTP %STATUS_CODE%
|
||||
@echo.
|
||||
echo Попытка повторного подключения через ...
|
||||
TIMEOUT /T 5
|
||||
cls
|
||||
for /f %%i in ('curl --write-out %%{http_code} --silent --output /dev/null --insecure https://raw.githubusercontent.com/amd64fox/SpotX/main/Install_Rus.ps1') do set STATUS_CODE=%%i 2>nul
|
||||
if "!STATUS_CODE!" EQU "200 " (
|
||||
cls
|
||||
chcp 866 >nul
|
||||
powershell -Command "& {[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12}"; "& {(Invoke-WebRequest -UseBasicParsing 'https://raw.githubusercontent.com/amd64fox/SpotX/main/Install_Rus.ps1').Content | Invoke-Expression}"
|
||||
) else (
|
||||
echo Снова ошибка
|
||||
@echo.
|
||||
echo Попробуйте запустить спустя некоторое время
|
||||
@echo.
|
||||
echo Скрипт остановлен
|
||||
@echo.
|
||||
)
|
||||
)
|
||||
pause
|
||||
exit /b
|
||||
Reference in New Issue
Block a user