Mkvirtualenv: command not found 19.04

Trying to install Django Framework. This when I am trying to activate an virtual environment for the very first time:

mkvirtualenv test
mkvirtualenv: command not found

Location of the installation:

which virtualenvwrapper.sh
/usr/local/bin/virtualenvwrapper.sh

Update from research I didn't use sudo when installing. Here is tutorial one and tutorial two.

1

2 Answers

you use python3, but virtualenv uses python2 by default. So you need to modify it.

Add the following sentence at the end of the '~/.bashrc',to modify the default python and configure virtualenv:

VIRTUALENVWRAPPER_PYTHON=/usr/bin/python3
export WORKON_HOME=~/.environments
source /usr/local/bin/virtualenvwrapper.sh

and then reload this configuration file with the command:

source ~/.bashrc

I needed to change the command to mkdir and follow different steps.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like