Installation and Setup¶
Make sure you are running Fish 3.1+. If you are running an Ubuntu LTS release that has an older Fish version, install Fish via the Fish 3.x release series PPA.
The easiest way to install VirtualFish is by running:
python -m pip install --user virtualfish. If you’re using Pipx, it is better to use:
pipx install virtualfish.
Install the VirtualFish loader by running:
If you want to use VirtualFish with plugins, list the names of the plugins as arguments to the install command:
vf install compat_aliases projects environment
Note: After performing the above step, you will be prompted to run
exec fishin order to make these changes active in your current shell session.
VirtualFish doesn’t attempt to mess with your prompt. Since Fish’s prompt is a function, it is both much less straightforward to change it automatically, and much more convenient to simply customize it manually to your liking.
The easiest way to add the active virtual environment’s name to your prompt is
funced fish_prompt and add the following line somewhere:
if set -q VIRTUAL_ENV echo -n -s (set_color -b blue white) "(" (basename "$VIRTUAL_ENV") ")" (set_color normal) " " end
funcsave fish_prompt to save your new prompt to disk.
To un-install VirtualFish, run:
vf uninstall python -m pip uninstall virtualfish