iRedHat commited on
Commit
ef44fe3
·
verified ·
1 Parent(s): 7774a98

Upload my-install.bat

Browse files
Files changed (1) hide show
  1. my-install.bat +114 -0
my-install.bat ADDED
@@ -0,0 +1,114 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ @echo off
2
+ setlocal
3
+ chcp 65001 > nul
4
+ set target_dir=%~dp0
5
+ set custom_n=%target_dir%ComfyUI\custom_nodes
6
+ set py=%target_dir%python_embeded\
7
+
8
+ call :ColorText "=============================================================" "Yellow"
9
+ call :ColorText ".bat file for installing ComfyUI by Skiffbox" "Green"
10
+
11
+ call :ColorText "=============================================================" "Yellow"
12
+ echo Installing wget
13
+ curl --ssl-no-revoke -L -o wget.exe https://huggingface.co/iRedHat/iBat-ComfyUI/resolve/main/wget.exe
14
+ rem https://eternallybored.org/misc/wget/
15
+ call :ColorText "Install wget complete" "Green"
16
+
17
+ call :ColorText "=============================================================" "Yellow"
18
+ call :ColorText "Downloading and unzip python+git" "Green"
19
+ cd %target_dir%
20
+ %target_dir%wget.exe -c -q -O pygit.bat https://huggingface.co/iRedHat/iBat-ComfyUI/resolve/main/pygit.bat
21
+ call %target_dir%pygit.bat
22
+ rem del /f /q %target_dir%pygit.bat
23
+
24
+ cd %target_dir%
25
+ %py%python.exe install_modules.py
26
+
27
+ rem call :ColorText "=============================================================" "Yellow"
28
+ rem call :ColorText "Downloading ComfyUI" "Green"
29
+ rem cd %target_dir%
30
+ rem %target_dir%wget.exe -c -q -O comfy.bat https://huggingface.co/iRedHat/iBat-ComfyUI/resolve/main/comfy.bat
31
+ rem call %target_dir%comfy.bat
32
+ rem del /f /q %target_dir%comfy.bat
33
+
34
+ rem call :ColorText "=============================================================" "Yellow"
35
+ rem call :ColorText "Installing ComfyUI packages" "Green"
36
+ rem cd %target_dir%
37
+ rem %target_dir%wget.exe -c -q -O packages.bat https://huggingface.co/iRedHat/iBat-ComfyUI/resolve/main/packages.bat
38
+ rem call %target_dir%packages.bat
39
+ rem del /f /q %target_dir%packages.bat
40
+
41
+ rem call :ColorText "=============================================================" "Yellow"
42
+ rem call :ColorText "Installing Fixes for ComfyUI" "Green"
43
+ rem cd %target_dir%
44
+ rem %target_dir%wget.exe -c -q -O fix.bat https://huggingface.co/iRedHat/iBat-ComfyUI/resolve/main/fix.bat
45
+ rem call %target_dir%fix.bat
46
+ rem del /f /q %target_dir%fix.bat
47
+
48
+ call :ColorText "=============================================================" "Yellow"
49
+ call :ColorText "run menu.bat and install custom nodes" "Green"
50
+ cd %target_dir%
51
+ %target_dir%wget.exe -c -q -O menu.bat https://huggingface.co/iRedHat/iBat-ComfyUI/resolve/main/menu.bat
52
+ call %target_dir%menu.bat
53
+ rem del /f /q %target_dir%menu.bat
54
+
55
+ call :ColorText "=============================================================" "Yellow"
56
+ call :ColorText "Download update.bat file" "Green"
57
+ %target_dir%wget.exe -c -q -O update.bat https://huggingface.co/iRedHat/iBat-ComfyUI/resolve/main/update.bat
58
+ %target_dir%wget.exe -c -q -O Link_Creator.bat https://huggingface.co/iRedHat/iBat-ComfyUI/resolve/main/Link_Creator.bat
59
+ %target_dir%wget.exe -c -q -O rename_list.txt https://huggingface.co/iRedHat/iBat-ComfyUI/resolve/main/rename_list.txt
60
+ %target_dir%wget.exe -c -q -O update-git-pull.bat https://huggingface.co/iRedHat/iBat-ComfyUI/resolve/main/update-git-pull.bat
61
+ call %target_dir%update.bat
62
+
63
+ call :ColorText "=============================================================" "Yellow"
64
+ call :ColorText "Building run.bat file" "Green"
65
+ echo @echo off> run.bat
66
+ echo setlocal>> run.bat
67
+ echo chcp 65001 > nul>> run.bat
68
+ echo set target_dir=%~dp0>> run.bat
69
+ echo set PATH=%target_dir%git\bin;%target_dir%git\libexec\;%target_dir%python_embeded;%target_dir%python_embeded\Library\bin;%target_dir%python_embeded\Scripts>> run.bat
70
+ echo set COMFYUI_PATH=%target_dir%ComfyUI>> run.bat
71
+ echo set COMFYUI_MODEL_PATH=%target_dir%ComfyUI\models>> run.bat
72
+ echo %target_dir%python_embeded\python %target_dir%ComfyUI\main.py --auto-launch --lowvram>> run.bat
73
+ echo pause>> run.bat
74
+
75
+ call :ColorText "=============================================================" "Yellow"
76
+ call :ColorText "Starting ComfyUI - run.bat" "Green"
77
+ start "" "%target_dir%run.bat"
78
+
79
+ call :ColorText "=============================================================" "Yellow"
80
+ call :ColorText "Installation of ComfyUI and Nodes complete by Skiffbox" "Green"
81
+
82
+ pause
83
+ exit /b
84
+
85
+ :ColorText
86
+ setlocal
87
+ set text=%~1
88
+ set color=%~2
89
+ powershell -NoProfile -ExecutionPolicy Bypass -Command "Write-Host '%text%' -ForegroundColor %color%"
90
+ endlocal
91
+ exit /b
92
+
93
+ rem del /f /q %target_dir%update.bat
94
+ rem call :ColorText ".bat file install custom_nodes for ComfyUI by Skiffbox" "Green"
95
+
96
+ rem call :check_and_clone https://github.com/ltdrdata/ComfyUI-Manager ComfyUI-Manager
97
+ rem call :check_and_clone https://github.com/crystian/ComfyUI-Crystools ComfyUI-Crystools
98
+ rem call :check_and_clone https://github.com/11cafe/comfyui-workspace-manager comfyui-workspace-manager
99
+ rem call :check_and_clone https://github.com/hayden-fr/ComfyUI-Model-Manager ComfyUI-Model-Manager
100
+ rem call :check_and_clone https://github.com/talesofai/comfyui-browser comfyui-browser
101
+
102
+ rem :check_and_clone
103
+ rem if exist %custom_n%\%2 (
104
+ rem call :ColorText "%2 уже установлено, пропуск..." "yellow"
105
+ rem ) else (
106
+ rem call :ColorText "=============================================================" "Yellow"
107
+ rem call :ColorText "Installing %2" "Green"
108
+ rem %gi%git clone %1 %custom_n%\%2
109
+ rem if exist %custom_n%\%2\requirements.txt (
110
+ rem %py%python -m pip install -r %custom_n%\%2\requirements.txt
111
+ rem call :ColorText "=============================================================" "red"
112
+ rem )
113
+ rem )
114
+ rem exit /b