Last active
August 31, 2016 17:05
-
-
Save saxbophone/d69091b1067bd75605e4 to your computer and use it in GitHub Desktop.
A very annoying shell function - Prints out a stupid message from fortune via cowsay, to all terminals, then waits a number of seconds in the fibonacci scale before spawning itself into the background
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function meme() { | |
if [ "$1" -eq "1" ] && [ "$2" -eq "1" ] | |
then | |
wall <<< `cowsay "Hello! I am Cow, and I like to SAY things"` | |
else | |
wall <<< `fortune | cowsay` | |
fi | |
a=$1 | |
b=$2 | |
temp=$((a + b)) | |
sleep $temp | |
meme $2 $temp& | |
} | |
# call meme | |
meme 1 1; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment