- Get an SSD cloud server in less than a minute!
- Protect your important files with HubiC. Get your free 35GB account TODAY!
- Get paid for reading email!
- Earn cash while shopping for everyday household items and groceries
The fortune command can provide you with hours of entertainment. It shows a random saying, or fortune, when invoked. In Ubuntu you can get it with:
sudo apt-get install fortune-mod
There are several fortune packs you can get to get even more fortunes. to find out what all is available type:
apt-cache search fortune-
Fortune is very well documented, so to find out how to use it type:
You can create your own files for fortune as well. To do so, open your favorite text editor, and write whatever you want. To end a fortune type a % on a line by itself:
This is a cool fortune!
when you have all the fortunes you want in your file use the strfile command to make it’s .dat counterpart:
If you searched through the available fortune packs and installed the offensive fortunes you may be interested in a fortune file I made. It is full of Confucius sayings. Simply download the Confucius fortunes and extract it.
tar -xzvf Downloads/confucius.tar.gz
Then, you can use it by typing:
or, if you want to put it in fortune’s path so you will get them at random:
sudo mv ~/confucius* /usr/share/games/fortunes/off/
These are placed in the offensive fortune directory for a reason. So, if you are easily offended, do not download or use this file. If I find more good quotes to put in it I will update the file, so you may want to check back from time to time.
Here are some interesting things you can do with your newly downloaded Confucius fortune file. You can, of course, use your own file, or just let fortune pick from all files, although you may want to use the -s switch for short fortunes. In irssi:
/alias confucius /exec -o fortune /usr/share/games/fortunes/off/confucius
If you have xcowsay:
sudo apt-get install xcowsay
you can get an interesting login with this small script, save as confucius-login:
xcowsay “$(fortune /usr/share/games/fortunes/off/confucius)”
Go to the System menu, Preferences, Startup Applications and add the script confucius-login to the list.
You can also add:
to your ~/.bashrc for a saying when you open your terminal.
If you left the confucius files in your home directory, simply replace the path with:
I hope you enjoy these sayings as much as I do. If you have any Confucius sayings that you think are great that aren’t included in this file be sure to leave them in the comments and I may add them to the file.