Click to See Complete Forum and Search --> : Randomizing the MOTD
Nailz
12-15-2000, 12:18 PM
How do I set my MOTD to be random?
I have a list of messages that I'd like to display...funny quips, sayings, etc. But I don't want to go in and change it all the time. I want to supply a list and have it randomized? Any ideas or programs out there to do it?
------------------
$> cd /pub
$> more beer
Death on Wheels
12-15-2000, 01:00 PM
fortune
Do a search for gfortune on Freshmeat, then do a search for just fortune and you'll get a bunch of fortune files.
------------------
Kurt Weber
Shell scripts? Shell scripts? We don't NEED no stinkin' shell scripts!
White, heterosexual, middle-class, and proud!
I've never understood why Bill Gates would name his company after his penis.
Muzzafarath
12-15-2000, 01:24 PM
Or you could write a script that would be executed, say every 10 minutes with cron, and put random stuff into /etc/motd with it.
Death on Wheels
12-15-2000, 01:53 PM
Or, you could combine the two:
fortune > /etc/motd
Make it a cron job as root or else you won't be able to write to /etc/motd
------------------
Kurt Weber
Shell scripts? Shell scripts? We don't NEED no stinkin' shell scripts!
White, heterosexual, middle-class, and proud!
I've never understood why Bill Gates would name his company after his penis.