Posted: . At: 5:01 PM. This was 2 years ago. Post ID: 12224
Page permalink. WordPress uses cookies, or tiny pieces of information stored on your computer, to verify who you are. There are cookies for logged in users and for commenters.
These cookies expire two weeks after they are set.



Sponsored



Nice little program to print a nice ascii artwork and a message in your terminal.


The Cowsay program is very useful for printing information in your terminal. There are quite a few cow files allowing many useful avatars to print in your terminal.

Install this today.

jason@Yog-Sothoth » ~ » $ sudo apt install cowsay

Then run this command to list all the available *.cow files.

jason@Yog-Sothoth » ~ » $ ls /usr/share/cowsay/cows/
apt.cow        cock.cow		   dragon.cow		  flaming-sheep.cow  koala.cow	       moofasa.cow	 sheep.cow	  suse.cow	  unipony.cow
bud-frogs.cow  cower.cow	   duck.cow		  ghostbusters.cow   kosh.cow	       moose.cow	 skeleton.cow	  three-eyes.cow  unipony-smaller.cow
bunny.cow      daemon.cow	   elephant.cow		  gnu.cow	     luke-koala.cow    pony.cow		 snowman.cow	  turkey.cow	  vader.cow
calvin.cow     default.cow	   elephant-in-snake.cow  hellokitty.cow     mech-and-cow.cow  pony-smaller.cow  stegosaurus.cow  turtle.cow	  vader-koala.cow
cheese.cow     dragon-and-cow.cow  eyes.cow		  kiss.cow	     milk.cow	       ren.cow		 stimpy.cow	  tux.cow	  www.cow

Here is an example, using the Dragon and Cow to tell us the time.

jason@jason-Lenovo-H50-55:~/Documents$ cowsay -f dragon-and-cow `date`
 _______________________________
< Mon 27 Jun 2022 08:43:29 AEST >
 -------------------------------
                       \                    ^    /^
                        \                  / \  // \
                         \   |\___/|      /   \//  .\
                          \  /O  O  \__  /    //  | \ \           *----*
                            /     /  \/_/    //   |  \  \          \   |
                            @___@`    \/_   //    |   \   \         \/\ \
                           0/0/|       \/_ //     |    \    \         \  \
                       0/0/0/0/|        \///      |     \     \       |  |
                    0/0/0/0/0/_|_ /   (  //       |      \     _\     |  /
                 0/0/0/0/0/0/`/,_ _ _/  ) ; -.    |    _ _\.-~       /   /
                             ,-}        _      *-.|.-~-.           .~    ~
            \     \__/        `/\      /                 ~-. _ .-~      /
             \____(oo)           *.   }            {                   /
             (    (--)          .----~-.\        \-`                 .~
             //__\\  \__ Ack!   ///.----..<        \             _ -~
            //    \\               ///-._ _ _ _ _ _ _{^ - - - - ~

Let Calvin tell you your IP address in your terminal.

jason@jason-Lenovo-H50-55:~/Documents$ cowsay -f calvin `ip a | awk '/inet / { print $2 }' | sed -n 2p`
 ________________
< 192.168.1.2/24 >
 ----------------
 \                   .,
   \         .      .TR   d'
     \      k,l    .R.b  .t .Je
       \   .P q.   a|.b .f .Z%
           .b .h  .E` # J: 2`     .
      .,.a .E  ,L.M'  ?:b `| ..J9!`.,
       q,.h.M`   `..,   ..,""` ..2"`
       .M, J8`   `:       `   3;
   .    Jk              ...,   `^7"90c.
    j,  ,!     .7"'`j,.|   .n.   ...
   j, 7'     .r`     4:      L   `...
  ..,m.      J`    ..,|..    J`  7TWi
  ..JJ,.:    %    oo      ,. ....,
    .,E      3     7`g.M:    P  41
   JT7"'      O.   .J,;     ``  V"7N.
   G.           ""Q+  .Zu.,!`      Z`
   .9.. .         J&..J!       .  ,:
      7"9a                    JM"!
         .5J.     ..        ..F`
            78a..   `    ..2'
                J9Ksaw0"'
               .EJ?A...a.
               q...g...gi
              .m...qa..,y:
              .HQFNB&...mm
               ,Z|,m.a.,dp
            .,?f` ,E?:"^7b
            `A| . .F^^7'^4,
             .MMMMMMMMMMMQzna,
         ...f"A.JdT     J:    Jp,
          `JNa..........A....af`
               `^^^^^'`

Or what about a milk carton listing all of your network interfaces?

jason@jason-Lenovo-H50-55:~/Documents$ cowsay -f milk `ip link | grep -Po "(?<=^\d: |^\d\d:)[^:]+(?=:)"`
 ____________
< lo enp0s25 >
 ------------
 \     ____________ 
  \    |__________|
      /           /\
     /           /  \
    /___________/___/|
    |          |     |
    |  ==\ /== |     |
    |   O   O  | \ \ |
    |     <    |  \ \|
   /|          |   \ \
  / |  \_____/ |   / /
 / /|          |  / /|
/||\|          | /||\/
    -------------|   
        | |    | | 
       <__/    \__>

Cowsay is very useful, there are many ways it could be used in a script to tell the user something in a fun and entertaining way. Why not try it today and see what you can come up with?

if the cowsay-off package is installed, there are more adult cow files installed, such as this one.

jason@jason-Lenovo-H50-55:~/Documents$ cowsay -f bong `ps`
 _______________________________________
/ PID TTY TIME CMD 11624 pts/0 00:00:00 \
\ bash 13069 pts/0 00:00:00 ps          /
 ---------------------------------------
         \
          \
            ^__^ 
    _______/(oo)
/\/(       /(__)
   | W----|| |~|
   ||     || |~|  ~~
             |~|  ~
             |_| o
             |#|/
            _+#+_

A cow hitting the bong.

Many people are offended by this package, but in Ubuntu 18 it is optional, and I assume in Debian as well, so get over it. it is pretty funny. Also, it is up to the user to decide what they have on their system if it is at home.


Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.