Files
dotfiles/zsh/.virtual_env_config.zsh.debian.example

18 lines
430 B
Plaintext
Raw Normal View History

export WORKON_HOME=~/python-envs
mkdir -p $WORKON_HOME
source /usr/share/virtualenvwrapper/virtualenvwrapper.sh
function workon() {
if ! { [ "$TERM" = "screen" ] && [ -n "$TMUX" ]; } then
if ! { [ -z "$1" ] } then
tmux setenv VIRTUAL_ENV "$1"
fi
source /usr/share/virtualenvwrapper/virtualenvwrapper.sh
workon "$@"
fi
}
if [ -n "$VIRTUAL_ENV" ]; then
workon $VIRTUAL_ENV
fi