Have you ever seen someone displaying their Linux desktop with the Linux distro logo and system information inside their terminal? If yes, chances are he is using neofetch.
In this article, you will learn how to install neofetch on every Linux distribution, so you can have a cool and aesthetic terminal too.
What is Neofetch?
Neofetch is a tool to display your system information inside your terminal in an aesthetic way. It can display information about your hardware and software such as CPU, memory, VGA, kernel, uptime, and many other things.
neofetch can also display your Linux distro logos in ASCII, which makes your terminal look cooler and aesthetic. If you are not satisfied with the disto logo in ASCII, you can change it with your custom image. Pretty cool huh?
Furthermore, It is lightweight, easy to configure, and available on various Linux distributions. And that’s why I recommend installing it on your Linux machine.
How to install neofetch
neofetch is available on many Linux distros, so installing it should be easy because it should be available on most package managers.
Install neofetch on Ubuntu 22.04/Linux Mint
Make sure your package repositories are up to date. Enter the command below to update the repository
sudo apt update
After that, you can proceed to install neofetch with the following command.
sudo apt install neofetch
Wait until the installation process is finished.
Install neofetch on Arch Linux/Manjaro
Same with ubuntu, but this time it just uses one line command.
sudo pacman -Syy neofetch
It will update the package repositories first, after that it will automatically install neofetch.
Install neofetch on Fedora 36
For Fedora, you can install neofetch by using the rpm package manager.
sudo rpm install neofetch
Install neofetch on openSUSE
In openSUSE, you can use zypper to install neofetch
sudo zypper install neofetch
Neofetch command examples
Now you are going to learn some of neofetch command examples.
Check neofetch version
neofetch --version
After the installation is complete, you can run the command neofetch --version
to verify its version.
Default neofetch command
By default, neofetch displays information about your Linux distribution, logo, kernel version, uptime, CPU model, and more. Let’s see that in action by simply running the neofetch
command in your terminal.
Custom ASCII distro logo
neofetch --ascii_distro [distro-name]
You can customize the ascii distro logo with the command above, just change [distro-name] with your desired distro. for example:
neofetch --ascii_distro arch
neofetch --ascii_distro fedora
neofetch --ascii_distro ubuntu
the output will be something like this
Using custom config
neofetch --config /path/to/config.conf
Neofetch is pretty flexible, you can modify the look you want by using a custom configuration file. You can configure anything you want to display in neofetch by editing the config file.
Neofetch customization
Customization on neofetch can be done by editing the neofetch config file. The config file is located at ~/.config/neofetch/config.conf
.
To edit the config.conf file, you can use any text editor you want, but I recommend using nano because it is easy to use, especially for beginners. But before that, make sure to back up the default config.conf file, in case you want to reset the config in the future. To do that, you can run the command below
cp ~/.config/neofetch/config.conf ~/.config/neofetch/config.conf.bak
Now we can safely configure neofetch and make it look beautiful.
Custom display logo
Starting with a custom image logo, open the config.conf file using nano by entering the command below
nano ~/.config/neofetch/config.conf
Now you should already be inside the nano text editor, press CTRL + W, enter “image_backend” and press enter. You should see some configurations like this
edit the image_backend value from ascii to w3m. it should be like this
scroll a little bit, you will find a line starting with image_source. edit from auto to the path of the image you want to display on neofetch. For this example, the path is /home/linuxspin/Pictures/arch-linux-logo.png
. The linuxspin part should be changed with your Linux username.
the configuration should look like this.
Press CTRL + O
to save the file, and press CTRL + X
to exit from nano.
Now try to run neofetch again, and it should be displaying the image in it.
Display only certain info
Neofetch gives us the flexibility to enable or disable information to display. Whether you want to display more or fewer stats, both are possible. You just need to edit the config.conf file again, and specify which info you want to disable or enable.
Once again open the config.conf file using nano
nano ~/.config/neofetch/config.conf
at the very top of the configuration, you should see a configuration like this
print_info() {
info title
info underline
info "OS" distro
info "Host" model
info "Kernel" kernel
info "Uptime" uptime
info "Packages" packages
info "Shell" shell
info "Resolution" resolution
info "DE" de
info "WM" wm
info "WM Theme" wm_theme
info "Theme" theme
info "Icons" icons
info "Terminal" term
info "Terminal Font" term_font
info "CPU" cpu
info "GPU" gpu
info "Memory" memory
# info "GPU Driver" gpu_driver # Linux/macOS only
# info "Disk" disk
# info "Battery" battery
# info "Font" font
# info "Song" song
# [[ "$player" ]] && prin "Music Player" "$player"
# info "Local IP" local_ip
# info "Public IP" public_ip
# info "Users" users
# info "Locale" locale # This only works on glibc systems.
info cols
}
These are basically lists of stat that will be displayed in neofetch. Every line that starts with # means it won’t be displayed in neofetch.
Add # to every line you don’t want to include in your neofetch stats and remove # from the beginning of the line if you want to include it.
This is an example configuration
Once you are done configuring your neofetch config, save your file and exit from nano. Now run neofetch again, and see the difference.
Conclusion
After reading this guide, you should now know how to install and use neofetch! This tool is incredibly useful for getting system information and making your terminal look more stylish. Give it a try and see for yourself!