xxxxxxxxxx
//create the virtual environment for Mac and Linux
python -m venv env
// or
python3 -m venv env
//activate virtual environment for Mac and Linux
source env/bin/activate
xxxxxxxxxx
//to create the virtual environment in windows
python -m venv env
// or
python3 -m venv env
//to activate virtual environment in windows
source env/Scripts/activate
//to disable virtual environment in windows
deactivate
xxxxxxxxxx
python3 -m venv tutorial-env
#name : tutorial-env
tutorial-env\Scripts\activate #activate env
deactivate #deactivate env
xxxxxxxxxx
#-------FOR WINDOWS----------#
#installing venv
py -m pip install --user virtualenv
#creating virtual env
py -m venv env
#activating virtual env
.\env\Scripts\activate
xxxxxxxxxx
python3.8 -m pip install --user virtualenv
python3.8 -m virtualenv --help