Fix looping and provide clear information

This commit is contained in:
Ajin Abraham
2021-08-05 15:38:37 -07:00
parent 90ed349212
commit 935ba9e152
+10 -4
View File
@@ -1,11 +1,17 @@
@echo off
rem Python Check
set /a count=0
where python >nul 2>&1 && (
echo [INSTALL] Python is available
echo [INSTALL] Checking for Python version 3.8+
:redo
rem Python Version Check
for /F "tokens=* USEBACKQ" %%F IN (`python --version`) DO (
set var=%%F
if %count% lss 3 (
set /a count+=1
rem Python Version Check
for /F "tokens=* USEBACKQ" %%F IN (`python --version`) DO (
set var=%%F
)
) else (
exit /b
)
echo %var%|findstr /R "[3].[89]" >nul
if errorlevel 1 (