Often my wife asks me to run some errands while I am glued to my laptop. I reply – “OK. Will do in 10 minutes!” but invariably I forget it within seconds though I was willing to do it. This repeats several times and finally I get up after an hour or so. The same thing happened today when my landlord requested me to turn off the water pump after half an hour. If you have read this earlier post of mine you know that I can’t help it how hard I try to remember. So I started looking for a simple way to handle these situations without having to remember.
Pretty soon I found a smart way of doing it using at and zenity without installing any additional exotic software.
Here’s how I did it:
I created a new file in my home folder named mytodo. I added the following lines in it:
zenity --info --display=:0.0 --text \ "Time to get outta my face - your laptop" //added the second line so that I do not need to touch the first line
To get this reminder after 1 minute I ran the following in my terminal and closed it:
$ at -f mytodo now +1 min warning: commands will be executed using /bin/sh job 18 at Mon Apr 16 22:57:00 2012 $
To make the process simpler I have written a small C program. Download it from here.
$ reminder 5 time to get up! //where 5 is time in mins and rest is the string to pop-up
In order to remember anything now I just need to edit the second line in mytodo file and schedule it with required timespan using at from the terminal which I can get easily from the bash history.