-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcheck-comfyui-prerequisites.bat
More file actions
152 lines (133 loc) · 4 KB
/
Copy pathcheck-comfyui-prerequisites.bat
File metadata and controls
152 lines (133 loc) · 4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
@echo off
setlocal enabledelayedexpansion
echo ==================================================
echo ComfyUI Voraussetzungen-Check
echo ==================================================
echo.
:: Initialize variables
set PYTHON_OK=0
set GIT_OK=0
set PIP_OK=0
set COMFYUI_OK=0
:: Python Check
echo [1/4] Python wird ueberprueft...
python --version >nul 2>&1
if %errorlevel% neq 0 (
echo [X] Python nicht gefunden
echo Bitte installieren Sie Python 3.10+ von https://www.python.org/downloads/
echo Wichtig: "Add Python to PATH" aktivieren!
) else (
for /f "tokens=2" %%i in ('python --version 2^>^&1') do set PYTHON_VERSION=%%i
echo [OK] Python gefunden: %PYTHON_VERSION%
:: Check Python Version
python -c "import sys; exit(0 if sys.version_info >= (3, 10) else 1)" >nul 2>&1
if %errorlevel% neq 0 (
echo [X] Python Version zu alt (benoetigt 3.10+)
echo Gefunden: %PYTHON_VERSION%
) else (
echo [OK] Python Version OK
set PYTHON_OK=1
)
)
echo.
:: Git Check
echo [2/4] Git wird ueberprueft...
git --version >nul 2>&1
if %errorlevel% neq 0 (
echo [X] Git nicht gefunden
echo Bitte installieren Sie Git von https://git-scm.com/download/win
) else (
for /f "tokens=3" %%i in ('git --version 2^>^&1') do set GIT_VERSION=%%i
echo [OK] Git gefunden: %GIT_VERSION%
set GIT_OK=1
)
echo.
:: Pip Check
echo [3/4] Pip wird ueberprueft...
pip --version >nul 2>&1
if %errorlevel% neq 0 (
echo [X] Pip nicht gefunden
echo Pip sollte mit Python installiert werden
) else (
for /f "tokens=2" %%i in ('pip --version 2^>^&1') do set PIP_VERSION=%%i
echo [OK] Pip gefunden: %PIP_VERSION%
set PIP_OK=1
)
echo.
:: ComfyUI Check
echo [4/4] ComfyUI wird ueberprueft...
if exist "%USERPROFILE%\ComfyUI" (
echo [OK] ComfyUI Ordner gefunden: %USERPROFILE%\ComfyUI
if exist "%USERPROFILE%\ComfyUI\main.py" (
echo [OK] ComfyUI Hauptdatei gefunden
:: Check if ComfyUI is running (simple HTTP check)
powershell -Command "try { Invoke-WebRequest -Uri 'http://127.0.0.1:8188' -TimeoutSec 2 -UseBasicParsing | Out-Null; exit 0 } catch { exit 1 }" >nul 2>&1
if %errorlevel% equ 0 (
echo [OK] ComfyUI laeuft auf http://127.0.0.1:8188
set COMFYUI_OK=2
) else (
echo [!] ComfyUI installiert aber nicht gestartet
echo Starten Sie ComfyUI mit: python "%USERPROFILE%\ComfyUI\main.py"
set COMFYUI_OK=1
)
) else (
echo [X] ComfyUI Hauptdatei nicht gefunden
)
) else (
echo [X] ComfyUI nicht installiert
echo Download: https://download.comfy.org/windows/nsis/x64
)
echo.
:: Zusammenfassung
echo ==================================================
echo ZUSAMMENFASSUNG
echo ==================================================
if %PYTHON_OK% equ 1 (
echo [OK] Python: OK
) else (
echo [X] Python: FEHLT
)
if %GIT_OK% equ 1 (
echo [OK] Git: OK
) else (
echo [X] Git: FEHLT
)
if %PIP_OK% equ 1 (
echo [OK] Pip: OK
) else (
echo [X] Pip: FEHLT
)
if %COMFYUI_OK% equ 2 (
echo [OK] ComfyUI: LAEUFT
) else if %COMFYUI_OK% equ 1 (
echo [!] ComfyUI: INSTALLIERT (nicht gestartet)
) else (
echo [X] ComfyUI: FEHLT
)
echo.
:: Empfehlungen
if %PYTHON_OK% equ 0 (
echo [INFO] EMPFEHLUNG: Python installieren
echo https://www.python.org/downloads/
echo.
)
if %GIT_OK% equ 0 (
echo [INFO] EMPFEHLUNG: Git installieren
echo https://git-scm.com/download/win
echo.
)
if %COMFYUI_OK% equ 0 (
echo [INFO] EMPFEHLUNG: ComfyUI installieren
echo https://download.comfy.org/windows/nsis/x64
echo.
)
if %PYTHON_OK% equ 1 if %GIT_OK% equ 1 if %PIP_OK% equ 1 if %COMFYUI_OK% geq 1 (
echo [SUCCESS] ALLES BEREIT FUER COMFYUI!
if %COMFYUI_OK% equ 1 (
echo Starten Sie ComfyUI mit: python "%USERPROFILE%\ComfyUI\main.py"
)
) else (
echo [WARNING] Es werden noch Voraussetzungen benoetigt
)
echo ==================================================
pause