SoFunction
Updated on 2024-11-16

virtualenv Specifies the version of the python interpreter.

Use the following command to install virtualenv on your ubuntu system

sudo apt-get install python-virtualenv

When we create a virtual environment using the virtualenv command, the default python interpreter used is /usr/bin/python27 (and then a corresponding copy of that interpreter is created), so how do we specify the version of the interpreter?

Use the parameter -p

$ sudo virtualenv -p ~/anaconda3/bin/python test

The above method of specifying the version of python interpreter by virtualenv is all that I have shared with you.