Get fortune cookies on your terminal

crismblog
  12 years ago
  14

This is a purely fun thing. You might wanna get your daily fortune cookie whenever you open your terminal. Here’s a way to do this. You need to have fortune installed. So go ahead and install fortune.

sudo yum install fortune or

sudo apt-get install fortune

depending on your distro. Let’s try it out.I got this.

Looks good but it can be made much fancier. How abt having tux or a dead cow say the fortune cookie. Install cowsay the same way as you did for fortune. Let’s try it out.


Haha ! look a dead cow :P . There are a lot of options in cowsay . You can change the animal’s eyes, tongue etc … . Wouldn’t you like some fortune cookie to pop up whenever you open a new terminal. It’s simple. Go ahead and edit the .bashrc file. Add the following line

fortune | cowsay -f tux

inside the if block in the file. Save the .bashrc file and then try opening a new terminal. Voila

Can’t beat that :D . You can experiment with fortune and cowsay. You can choose the type of cookies that you get with fortune like explicit, famous sayings etc.

Cheerios \m/

source: http://bitsquad.co.in/2011/01/get-fortune-cookies-on-your-terminal/

Comments
sirfmoyo 7 years ago

any idea how i can enable this in opensuse


jahid_0903014 10 years ago

funny...


mintweike 12 years ago

Cool! I get my deer back again!

By the way! Linus Torvalds really did say that words?


crismblog 12 years ago

Many do not know what to do and why do these tutorials, even if simple.


chassum 12 years ago

That's what I'm talking about! Seriously, little things like this can make the command-line more exciting for a whole new generation of Linux users.