This repository provides two batch scripts designed to simplify the creation and management of Python virtual environments on your system. With these scripts, you can quickly set up a new Python environment with just a few clicks, streamlining your development workflow.
A script that detects installed Python versions, allows custom naming of your virtual environment, offers an option to upgrade pip, and automatically places you inside the newly created environment.
- Download and Place the Script: Download
venv_create.bat
and place it in your desired directory. - Run the Script: Double-click the script to execute. It will display available Python versions for selection. The default selection is
1
. - Name Your Environment: Enter a name for your virtual environment when prompted. The default name is
venv
. - Upgrade pip (Optional): Choose whether to upgrade pip. The default option is
Yes
. - Install requirements.txt (Optional): Choose whether to run a
pip install -r requirements.txt
command in your new venv. The default option isYes
. - Access Your Environment: Upon completion, the script places you inside the virtual environment and creates an
activate_venv
script for re-entry in the future.
Venv.Setup.mp4
A streamlined version of the script for quick setup, skipping Python version selection and focusing on creating a virtual environment directly.
- Download and Place the Script: Obtain
venv_create_simple.bat
and place it in the target directory. - Run the Script: Execute the script. You will be prompted to name your virtual environment, with a default option provided.
- Access Your Environment: The script will finalize the environment creation and provide an
activate_venv
script for easy access in the future.
To specify a Python version, edit line 10 of venv_create_simple.bat
with your desired version.
By utilizing these scripts, developers can efficiently manage their Python environments, enhancing productivity and focusing more on development tasks.