Context I use virutalenv and virtualenvwrapper tomanage my development environments. Virtualenvwrapper consolidates all your virtualenvs into a single location, and can link a directory to a virtualenv. Once in a while, I need to change the name of my repo and/or virtual environment. This means I have to change a bunch of other stuff.
If the project directory is moved/changed/renamed, modify the following:
In the virtualenvs directory (usually ~/.virtualenvs/<virtualenv_name>) there is a ‘.project’ file. Modify the path here to get the workon command to work correctly.
In the ~/.virtualenvs/<virtualenv_name>/bin/ directory, open up the ‘activate’ file. Change the ‘VIRTUAL_ENV’ variable to reflect the new path. This will change the bash prompt when the virtualenv is activated.