3REM Windows Command Line Script (Batch) to launch "pyenv-virtualenv-prefix.py".
9REM © 2025 Michael Paul Korthals. All rights reserved.
10REM For legal details see documentation.
14REM This script is located in the subfolder "bin"
15REM in the project main directory.
17REM Simply open it in Windows Explorer or call it by path
18REM in the Windows CMD terminal.
20REM The script returns RC = 0 or another value in case of
23REM This job is too challenging for Windows CMD language.
24REM Calling python script to bypass all the painful CMD problems.
25REM Using the Python version, which is globally set by "pyenv".
26call python "%~dp0pyenv-virtualenv-prefix.py" %*
28if %RC% equ 130 goto cancel
29if %RC% leq 5 goto finish
30if %RC% neq 0 goto error1
33REM Display error messages
36echo ␛[91mERROR Failed to determine the virtual environment prefix (RC = %RC%).␛[0m
37echo ␛[37mINFO Check if Python, "pyenv" and plugin "pyenv-virtualenv" are correctly installed/configured.␛[0m
40REM Cancel program silently
44REM Ignore I/O error, but return it