RU | EN | DE

1. Install Pyenv-win

winget install --id Microsoft.VisualStudio.2022.BuildTools -e
git clone https://github.com/pyenv-win/pyenv-win $HOME\.pyenv
$pyenvPaths = "$HOME\.pyenv\pyenv-win\bin;$HOME\.pyenv\pyenv-win\shims"
[Environment]::SetEnvironmentVariable("Path", $env:Path + ";" + $pyenvPaths, "User")
[Environment]::SetEnvironmentVariable("PYENV",      "$HOME\.pyenv\pyenv-win", "User")
[Environment]::SetEnvironmentVariable("PYENV_ROOT", "$HOME\.pyenv\pyenv-win", "User")
[Environment]::SetEnvironmentVariable("PYENV_HOME", "$HOME\.pyenv\pyenv-win", "User")
$pyenvPaths = "$HOME\.pyenv\pyenv-win\bin;$HOME\.pyenv\pyenv-win\shims"
if (-not ($env:Path -split ';' | Where-Object { $_ -eq "$HOME\.pyenv\pyenv-win\bin" })) {
[Environment]::SetEnvironmentVariable("Path", $env:Path + ";" + $pyenvPaths, "User")
}

2.  Install Python

pyenv install 3.10.11
pyenv install 3.11.0
pyenv install 3.11.9
pyenv install 3.12.9
pyenv install 3.13.5

3. Set global version

pyenv global 3.11.9

4. Set local version for Folder

pyenv local 3.11.9

5. Virtual Environment

5.1. Virtual Environment

python -m venv .venv

5.2. Active Environment

.\.venv\Scripts\Activate.ps1

5.3. Install pip

python -m pip install --upgrade pip

5.4. Install all other

pip install requests
pip install -r requirements.txt
pip freeze > requirements.txt

5.5. deactivate

deactivate