lunch monitor

Submitted scripts and programs
Forum rules
Your own work only.
User avatar
wuxmedia
Grasshopper
Posts: 6445
Joined: Wed Oct 17, 2012 11:32 am
Location: Back in Blighty
Contact:

lunch monitor

Unread post by wuxmedia » Wed Jun 08, 2016 1:19 pm

So I get an hours lunch, lucky me.
I normally forget when I started, no body snaps at me if i'm late (or wake up my jabber client basically)
but I was bored:

Code: Select all

#!/bin/bash
#Lunch alarm, requires 'toilet'
echo "LUNCH!!" 
date
sleep 10s
while true 
do
printf '\e[?5h'  # Turn on reverse video
toilet "WORK"
sleep .5s 
printf '\e[?5l'  # Turn on normal video
toilet "TIME"
sleep .5s
done
have to run it with this alias:

Code: Select all

alias lunch="lunch.sh ; printf '\e[?5l'"
in case the terminal stays inverted.
couldn't work out how to do a proper 'trap' function
"Seek, and Ye shall find"
"Github | Chooons | Site"

User avatar
GA-KO
Oyster-Slurper
Posts: 22
Joined: Sun Mar 20, 2016 8:13 am

Re: lunch monitor

Unread post by GA-KO » Fri Jun 10, 2016 6:51 pm

Needs a

Code: Select all

toilet "Toilet Time"
last 10 minutes of lunch break
so you don't forget.

User avatar
wuxmedia
Grasshopper
Posts: 6445
Joined: Wed Oct 17, 2012 11:32 am
Location: Back in Blighty
Contact:

Re: lunch monitor

Unread post by wuxmedia » Fri Jun 10, 2016 9:18 pm

^ hah!
"Seek, and Ye shall find"
"Github | Chooons | Site"

machinebacon
Baconator
Posts: 10253
Joined: Thu Sep 16, 2010 11:03 am
Location: Pfälzerwald
Contact:

Re: lunch monitor

Unread post by machinebacon » Wed Jun 15, 2016 5:53 pm

/moving to /usr/local/bin/ :)
..gnutella..

User avatar
wuxmedia
Grasshopper
Posts: 6445
Joined: Wed Oct 17, 2012 11:32 am
Location: Back in Blighty
Contact:

Re: lunch monitor

Unread post by wuxmedia » Wed Jun 15, 2016 6:04 pm

oh - thanks, you know as root at work I would never just put dodgy scripts into /usr/bin or /bin/ *ahem*
"Seek, and Ye shall find"
"Github | Chooons | Site"

machinebacon
Baconator
Posts: 10253
Joined: Thu Sep 16, 2010 11:03 am
Location: Pfälzerwald
Contact:

Re: lunch monitor

Unread post by machinebacon » Wed Jun 15, 2016 6:06 pm

...or /sbin :D

noooo never ;)
..gnutella..

Post Reply