Servers on Rcs are deployed with the Bash shell by default. Fish (friendly interactive shell) is an alternate shell that tries to be more user-friendly and interactive than other shells. In this tutorial, we will install Fish on a Debian 10 Rcs instance.
Prerequisites
Install Fish on a fully updated Debian 10 instance.
Install Fish
Install Fish with the following command.
$ sudo apt install fish -yLaunch Fish
To start Fish:
$ fishTo exit Fish:
$ exitConfigure Fish
Start with a default configuration file.
$ cp /usr/share/fish/config.fish ~/.config/fishTo change the configuration, open the configuration file with a text editor.
$ nano ~/.config/fish/config.fishFor example, to remove the default welcome message, add the following line at the beginning of the file.
set -g -x fish_greeting ''How to Use Suggestions
Fish will suggest file names and commands as you type them. For instance, if you would like to edit the file in your home directory called test.txt, you can type nano ~/te, and Fish will preview the rest of the filename. Press the Right arrow key to accept the suggestion. Fish offers more complete suggestions than Bash because it indexes the man pages and gathers program arguments.
Variables
To set variables in Fish, use the set command. For instance, to assign the variable Foo the value BAR:
$ set Foo BARTo unset Foo:
$ set -e FooDisplay all variables
Use the env command to display all variables..
$ envHelp
Use the help command for online documentation.
$ helpSet the Default Shell
To make Fish your default shell, use chsh.
$ chsh -s /usr/bin/fishLog out, and log back in for this to take effect.
To restore Bash as the default shell, use chsh, log out, and log back in.
$ chsh -s /usr/bin/bashConclusion
For more information and configuration options, see the Fish shell documentation.