Since Python 3.3 venv is a module found in the standard library of Python. It can replace virtualenv / virtualenvwrapper. Creating a virtual environment is as simple as this:
python3 -m venv ~/.pyvenv/iplogger-3.4
source ~/.pyvenv/iplogger-3.4/bin/activate
# I didn't need the step below, don't know when it is required:
#curl https://raw.githubusercontent.com/pypa/pip/master/contrib/get-pip.py | python
### If you want to include site packages of your system:
python3 -m venv --system-site-packages ~/.pyvenv/system-3.4
source ~/.pyvenv/system-3.4/bin/activate
# I didn't need the step below, don't know when it is required:
#curl https://raw.githubusercontent.com/pypa/pip/master/contrib/get-pip.py | python
Resources
- In Python’s documentation, read venv — Creation of virtual environments or
- have a look at this question on StackOverflow: Python3 Virtual Environment and PIP.