Skip to content

Latest commit

 

History

History
61 lines (43 loc) · 1.21 KB

File metadata and controls

61 lines (43 loc) · 1.21 KB
  1. Install with pip
  2. Check the version

If you want to you can think of an environment as a VM (but it isn't)

Working in it

Start working in the enviroment - Always do this when using it

# LINUX
source thenewenvironment/bin/activate
(virtualenv_name)$

# WINDOWS
cd ~/code/py_vm
Scripts\activate

Stop using the environment

deactivate

Create a new

Create a new environment

A directory will be created where you are in the library. cd here when using it.
This is where Python packages will be installed

mkdir ~/code/py_vm
cd ~/code/py_vm
virtualenv thenewenvironment

Select a specific Python version for the environment

virtualenv -p /usr/bin/python3 thenewenvironment
# OR
virtualenv -p /usr/bin/python2.7 thenewenvironment

Install

Install with pip

pip3 install virtualenv

Check the version

virtualenv --version