From 0aa14fabb4ff8112dfdaced4ac143ebcedf1fc0b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gourieff=20=7C=20=E5=8F=A4=E4=BB=81?= Date: Sun, 30 Aug 2026 15:11:22 +0700 Subject: [PATCH] UPD: Desktop friendly install.bat https://codeberg.org/Gourieff/comfyui-reactor-node/issues/52 --- install.bat | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/install.bat b/install.bat index 290195e..0be4b5b 100644 --- a/install.bat +++ b/install.bat @@ -1,22 +1,25 @@ @echo off setlocal enabledelayedexpansion -:: Try to use embedded python first -if exist ..\..\..\python_embeded\python.exe ( - :: Use the embedded python +:: Try to use the Desktop version's venv python first +if exist ..\..\.venv\Scripts\python.exe ( + :: Use the ComfyUI Desktop venv python + set PYTHON=..\..\.venv\Scripts\python.exe +) else if exist ..\..\..\python_embeded\python.exe ( + :: Use the embedded python (portable version) set PYTHON=..\..\..\python_embeded\python.exe ) else ( - :: Embedded python not found, check for python in the PATH + :: Neither found, check for python in the PATH for /f "tokens=* USEBACKQ" %%F in (`python --version 2^>^&1`) do ( set PYTHON_VERSION=%%F ) if errorlevel 1 ( - echo I couldn't find an embedded version of Python, nor one in the Windows PATH. Please install manually. + echo I couldn't find a venv python ^(Desktop^), an embedded python ^(Portable^), nor one in the Windows PATH. Please install manually. pause exit /b 1 ) else ( :: Use python from the PATH (if it's the right version and the user agrees) - echo I couldn't find an embedded version of Python, but I did find !PYTHON_VERSION! in your Windows PATH. + echo I couldn't find a venv or embedded version of Python, but I did find !PYTHON_VERSION! in your Windows PATH. echo Would you like to proceed with the install using that version? (Y/N^) set /p USE_PYTHON= if /i "!USE_PYTHON!"=="Y" ( @@ -30,6 +33,7 @@ if exist ..\..\..\python_embeded\python.exe ( ) :: Install the package +echo Using Python: %PYTHON% echo Installing... %PYTHON% install.py echo Done^!