You are not logged in.
#!/bin/bash
COW_PATH=/usr/share/cows
files=($COW_PATH/*.cow)
N=${#files[@]}
((N=RANDOM%N))
cow=${files[$N]}
h=`date +%H`
case $h in
0[0-9]|1[0-1]) greeting="Good morning!"
;;
1[2-9]) greeting="Good afternoon!"
;;
2[0-4]) greeting="Good evening!"
;;
esac
cowsay -f $cow $greeting
exit 0Tip: May need to modify COW_PATH- This was tested on Arch Linux.
Last edited by lurka (2012-05-08 22:56:56)
Offline
moo! what are the different cows?
Offline
^ Morning Rho!
ls /usr/share/cowsay/cows/Start Distrohopping here! -> Break your own...
VSIDO
LinuxCNC
Frugalware <- It's all just a kernel.
Offline
Congratulations on your first AI.
I'm so meta, even this acronym
Offline
Congratulations on your first AI.
That's what people always say! D:
hah
Offline
And every time they do, 2ct are sent to numbered account in Switzerland.
I'm so meta, even this acronym
Offline
Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.