How to Install Fish Shell on Linux

Chưa phân loại
In Linux, shell is one of the most important parts. Every Linux user have used the shell more than once in the entire usage time. The terminal is the place where the shell is used. Generally, all the Linux systems come up with Bash shell pre-installed. It’s very simple, but lacks the power of advanced and modern features. For better result, it’s recommended to switch to Fish shell – a modern, innovative and productive shell.

Features of Fish shell

I know that the name is a bit funny – “Fish” shell! Don’t let the name fool you as it comes up with a ton of useful features. The main features include –

  • Autosuggestion – When you start typing, you’ll see suggestion of the command line. We’ll get to it after the installation part is complete.
  • Glorious colors – Fish shell supports 24-bit true color for making the terminal even more appealing.
  • Works out of the box – You don’t have to configure Fish shell from the starting to enjoy it. Instead, all you need is just start enjoying the shell.
  • Scripting – Fish shell supports easier scripting.
  • “man” page completions – Fish shell automatically parses the existing “man” pages and presents them in a nice, charismatic way.

Installing Fish shell

It’s time to install the shell in our system. Let’s fire up the terminal!

Run the following command(s) according to your Linux distro.

  • Ubuntu
  • sudo apt install fish
  • Debian
  • sudo apt-get install fish
  • Fedora
  • sudo dnf install fish
  • CentOS
  • OpenSUSE
  • sudo zypper install fish
  • Arch Linux
  • sudo pacman -S fish
  • Guix
  • guix package -i fish
  • Universal method

This method isn’t recommended as it requires compiling & installing from the source. Uninstalling the shell may be a difficulty in this case. For this method, download the latest version of Fish shell (compressed).

Extract the file in a folder:

tar -xvzf fish-2.7.1.tar.gz

Change the working directory and build Fish shell:

cd fish-2.7.1/

sudo make

Install the software:

sudo make install

Switching to Fish shell

Now, it’s time to change the default shell of terminal. Run the following command:

chsh -s /usr/bin/fish

Restart the terminal and behold the beautiful Fish shell!

Fish shell usage

There’s no basic difference between Fish and Bash shell. Everything is just as same.

The first main difference that will catch your eyes is the coloring. Fish shell is more colorful than the classic Bash shell. However, the coloring also depends a lot on the terminal settings for color. The highlighting is really useful.

Another awesome feature is the availability of the command. For example, if I type “/bin/linuxhint”, it’ll show the line in a red color, indicating that it’s not a valid command.

But if I type “/bin/bash”, it’ll look normal.

Another interesting feature is the suggestion bar. It remembers your usage pattern and can suggest you the right command at the right moment. Just press the → key when the suggestion appears.

These are all the basic features, but what about the others? If you want to go in-depth on Fish shell, you should give this online Fish shell playground a try. It comes up with a huge number of tutorials and other tricks.

Stay connected with linuxhint for more awesome tricks and tips!

Sandclock IDC thành lập vào năm 2012, là công ty chuyên nghiệp tại Việt Nam trong lĩnh vực cung cấp dịch vụ Hosting, VPS, máy chủ vật lý, dịch vụ Firewall Anti DDoS, SSL… Với 10 năm xây dựng và phát triển, ứng dụng nhiều công nghệ hiện đại, Sandclock IDC đã giúp hàng ngàn khách hàng tin tưởng lựa chọn, mang lại sự ổn định tuyệt đối cho website của khách hàng để thúc đẩy việc kinh doanh đạt được hiệu quả và thành công.
Bài viết liên quan

Installing Google Chrome on Debian 10

Firefox is the default browser of Debian 10 Buster. But, Google Chrome is many peoples favorite web browser. If you really...

[Snort] Hướng dẫn cài đặt snort

Snort là một hệ thống phát hiện, phòng ngừa xâm nhập hệ thống (IDS/IPS) mã nguồn mở được viết...

Debian: debian_frontend=noninteractive

In this guide we’ll discuss the advantages of Debian’s configuration engine, how configuration dialogs work, how to...
Bài Viết

Bài Viết Mới Cập Nhật

Hướng dẫn chuyển đổi windows server windows evaluation to standard và active windows server 2008 + 2012 + 2016 + 2019

How to Update Ubuntu Linux

Squid Proxy Manager cài đặt và quản lý Proxy Squid tự động trên ubuntu

Hướng dẫn cài đặt Apache CloudStack

Hướng dẫn ký file PDF bằng chữ ký số (chữ ký điện tử) và sửa lỗi mới nhất 2021 foxit reader