python - virtualenvwrapper hooks aren't loading automatically -
(following marina mele's taskbuster django tutorial)
the virtualenv called tb_test. in $virtual_env/bin/ (~/.virtualenvs/tb_test) pasted postactivate file general hooks folder in $workon_home , added 2 lines looks this:
$virtual_env/bin/postactivate #!/bin/zsh # hook sourced after every virtualenv activated.
echo "helo" export django_settings_module="taskbuster.settings.testing"
however, upon running workon tb_test
virtualenv gets activated , postactivate hook not being loaded. no "helo" echo :-(
works me. double check using workon
activate virtualenv (not source bin/activate
), , activating right virtualenv.
if still not work, please provide more information environment (os, versions of involved packages, etc.). did modify of other virtualenv-wrapper hooks?
update: maybe created hook in wrong path? if create virtualenv mkvirtualenv
, should create postactivate
file in right place, have edit it. should in location:
~/.virtualenvs/tb_test/bin/postactivate
to clarify: not in ~/.virtualenvs/tb_test/postactivate
Comments
Post a Comment