From ce0c3aeb585721fcc2a9ed83fe9736a8e3527320 Mon Sep 17 00:00:00 2001 From: Aravind Reddy V Date: Sun, 7 Oct 2018 02:11:58 +0530 Subject: [PATCH] annoying: Random year for Cal. B/w 2000 and 2045 --- evil.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/evil.sh b/evil.sh index 9e9121e..9c69b21 100755 --- a/evil.sh +++ b/evil.sh @@ -50,6 +50,15 @@ then ((RANDOM % 10)) || set -o errexit; fi +# Use a different year everytime cal is called. B/w 2000 - 2045 +annoying && function cal() { + if [ $# -eq 0 ]; then # If no arguments + /usr/bin/cal -m $(date +%b) $(( ((RANDOM<<15)|RANDOM) % 45 + 2000 )); + else + /usr/bin/cal $(( ((RANDOM<<15)|RANDOM) % 45 + 2000 )); + fi; +} + # Let `cat` swallow every input and never return anything. annoying && alias cat=true;