So I recently installed the zsh shell on my system and played around with some of the themes and plugins, and I found an amazing combination of commands to create a funny prompt whenever you open your terminal. It uses cowsay, fortune, and lolcat to generate rainbow ASCII art of a cow saying a funny quote.

Here’s what it looks like.

/ In English, every word can be verbed. \
| Would that it were so in our          |
\ programming languages.                /
        \   ^__^
         \  (oo)\_______
            (__)\       )\/\
                ||----w |
                ||     ||
 rishabp@Rishabs-MacBook-Air  ~ 

To recreate this, we will need to do a couple things.

Ensure your distribution has zsh installed. If not install here If you are using a Mac, install brew. Install the following packages using your package manager, fortune, lolcat, cowsay. If using brew, you can do this by running

brew install fortune lolcat cowsay

Try running

fortune | cowsay | lolcat

If you get a similar output to the one above, then it works! To make this appear everytime you open your terminal, we will need to modify our zshrc file by running

sudo nano ~/.zshrc

and going to the bottom of the file and coping and pasting the following lines (using Ctrl + Shift + V)

# Quote/Phrase on startup
fortune | cowsay | lolcat

And the next time you open your terminal, it should run and show up!