The best way is to use the package archive provided by the fish project to replace the packages that are the Ubuntu project project (which are very old and contain security issues).
The following commands subscribe your system to the Personal Package Archive launched by the fish developers, update the list of packages, and finally update or install the fish:
sudo add-apt-repository ppa:fish-shell/release-2
sudo apt-get update
sudo apt-get install fish
As an added bonus, by running apt-get upgradeafter these steps, always make sure you have the latest version of fish.
source
share