Reputation: 433
virtualenvwrapper
instructs us to put source /usr/local/bin/virtualenvwrapper.sh
in our .bash_profile
. Why?
I see it creates .virtualenvs
the first time it's run. Is .virtualenvs
newly created every time I $ source .bash_profile
? If yes, is this so .virtualenvs
can be updated as virtualenvwrapper
is updated?
Upvotes: 1
Views: 256
Reputation: 18080
That's just a helper module to bind your shell and virtualenvwrapper
together. It defines such helpers as:
workon
to activate a virtualenv
mkvirtualenv
to create new onesrmvirtualenv
to delete unused virtualenv
svirtualenvwrapper
to see the full listWhen you are source
ing something it is pretty much the same as import
ing in python
. And no, it does not create ~/.virtualenvs
folder each time.
It also does some preparations: checking that ~/.virtualenvs
folder is in place and that hooks are executed properly.
You can always see the source code of this file by running: cat /usr/local/bin/virtualenvwrapper.sh
.
Upvotes: 1