For many, the Linux terminal is a functional but unexciting tool.
But it doesn't need to be that way! With a few simple tweaks, it can become a canvas for creativity and personalization.
From colorful prompts to quirky screensavers, here’s a guide to turning your terminal into a unique and engaging space.
Customize the Linux Terminal
Ready to become a Linux master by learning how to customize your terminal?
Custom Prompts with PS1
To me, the first step to personalizing your terminal is customizing the prompt using the PS1 environment variable.
This variable defines how the terminal prompt appears, with options to display your username (\u), the current working directory (\w), and even colors.
For example, a custom prompt might look like this:
PS1="\[\033[1;32m\]\u@\h:\[\033[1;34m\]\w\$\[\033[0m\] "
Here, the colors green and blue distinguish different elements, and the dollar sign ($) marks the end of the prompt.
Adding emojis, such as a penguin or a rocket, can further enhance the prompt’s visual appeal.
With these changes, every command you type feels a little more personal.
Note, that by saving this configuration to the ~/.bashrc file, it becomes permanent.
If you're using other shells like Zsh, you can adapt your setup for your configuration files.
System Info with Neofetch
Neofetch is a popular tool for displaying system information alongside a sleek ASCII art logo of your Linux distribution.
Installing it is straightforward:
sudo apt install neofetch
Once installed, running neofetch displays details like OS version, kernel, memory usage, and more.
To make this feature greet you every time you open a terminal session, add the following line to your ~/.bashrc:
echo neofetch >> ~/.bashrc
With Neofetch, your terminal becomes not only informative but also visually striking.
Injecting Fun with Fortune, Cowsay, and Lolcat
Why settle for a plain terminal when you can be greeted by a colorful, fortune-telling cow?
This trio of commands adds humor and flair to your terminal.
- Fortune generates random quotes or quips.
- Cowsay wraps the message in ASCII art of a cow (or other characters).
- Lolcat adds vibrant rainbow colors to the text.
A combined command might look like this:
fortune | cowsay | lolcat
By appending this to your ~/.bashrc, every new terminal session begins with a whimsical and colorful message.
It’s a small addition that can brighten your day.
Turning Your Terminal into an Aquarium
For an unexpected twist, transform your terminal into a live animated aquarium with ASCIIquarium.
This tool simulates an underwater scene, complete with fish, sharks, and other aquatic life, all rendered in ASCII art.
Install ASCIIquarium and set up a script to run it as a screensaver:
sudo apt install asciiquarium
A simple script can monitor terminal activity and activate the aquarium after a period of idleness. For example:
#!/bin/bash
while true; do
read -t 120 -n 1 key # Wait for 120 seconds for user input
if [ $? -gt 128 ]; then # If no input within 120 seconds
asciiquarium
fi
done
Make the script executable and add it to your terminal’s configuration file for automatic activation.
Watching fish swim across your terminal screen is not only fun, but it may also be a conversation starter in your office!
If you're hungry to take your Linux skills to the next level, check out the rest of our Linux Mastery articles tutorials, including:
Wrapping Up
These simple customizations can transform your terminal from a utilitarian tool into an engaging and personal workspace.
Whether it’s a dynamic prompt, informative ASCII art, quirky cows, or a lively aquarium, the Linux terminal can reflect your personality and make daily tasks more enjoyable.
So, the next time someone calls the terminal boring, you can proudly show them otherwise.
With a few creative tweaks, your terminal can be as unique and vibrant as you are.