Skip to content

Commit

Permalink
pyenv-win compatibility - another approach (#16287)
Browse files Browse the repository at this point in the history
  • Loading branch information
viking1304 authored Oct 29, 2024
1 parent 14c6d6c commit f31faf6
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion webui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,16 @@ if exist webui.settings.bat (
call webui.settings.bat
)

if not defined PYTHON (set PYTHON=python)
if not defined PYTHON (
for /f "delims=" %%A in ('where python ^| findstr /n . ^| findstr ^^1:') do (
if /i "%%~xA" == ".exe" (
set PYTHON=python
) else (
set PYTHON=call python
)
)
)

if defined GIT (set "GIT_PYTHON_GIT_EXECUTABLE=%GIT%")
if not defined VENV_DIR (set "VENV_DIR=%~dp0%venv")

Expand Down

0 comments on commit f31faf6

Please sign in to comment.