Blog #2
Cowsay!
Linux Command Line Fun?
Configurable talking Characters in ASCII art
February 28th, 2023Cowsay is a decades-old fun and whimsical command-line program in Linux systems that generates an ASCII art cow with speech or thought bubbles that display messages. This program is an implementation of the Unix cowsay program originally written in Perl and can be installed on most distributions using the package manager (Homebrew, in my case).
Syntax and Use
The basic syntax for using cowsay is simple. In a terminal window, type "cowsay" followed by your message, and an ASCII art cow will appear on your screen with your message in a speech bubble. For example, typing "cowsay Hello, World!" will generate the following output:
Hello, Cow!Additional Animals
In addition to the standard cow, you can use the “-f” flag to access the many other animals and characters you can use with cowsay, such as a cat, a block of cheese, a dragon, a turtle, and even a turkey. There are a ton to choose from and some seriously wild and ridiculous ones. To use a different animal, simply add the "-f" flag followed by the corresponding name of the animal or character. For example, if you type 'cowsay -f duck "quack, I'm a duck!" ', you'll get:
Look, a duck!Cowsay has a wide variety of other options that you can use to customize your cow and speech bubble. You can change the size and position of the speech bubble, change the alignment of the text within the speech bubble, and even make the cow say your message in a different language.
Paarthurnax?Final Thoughts
Cowsay is a great way to add a bit of fun and personality to your command-line interactions, and also a great way to lose a bunch of time exploring the hilarious ASCII implementations people have created over the years (some of which are NSFW). It's also a useful tool for creating custom ASCII art messages for your friends or colleagues. Whether you're using it to entertain yourself or to share a message with your friends and colleagues, cowsay is sure to bring a smile to your face. Try experimenting with different animals and messages to see what you can come up with!
Thanks for Reading! :)