Fish shell is friendlier yet you might face trouble while using with virtualenv
or virtualenvwrapper
. Alternatively virtualfish
exists for the rescue. Just follow the below sequence to start using Fish shell with virtualenv.
sudo pip install virtualfish
$ echo "eval (python -m virtualfish)" > ~/.config/fish/config.fish
fish_prompt
by $ funced fish_prompt --editor vim
and add the below lines and close the vim editorif set -q VIRTUAL_ENV
echo -n -s (set_color -b blue white) "(" (basename "$VIRTUAL_ENV") ")" (set_color normal) " "
end
Note: If you are unfamiliar with vim, simply supply your favorite editor like this `$ funced fish_prompt --editor nano` or `$ funced fish_prompt --editor gedit`
funcsave
funcsave fish_prompt
vf new
vf new my_new_env # Make sure $HOME/.virtualenv exists
-p
flagvf new -p python3 my_new_env
vf deactivate
& vf activate another_env
Official Links: