[Ubuntu 9.04] Plan a visual message
Intro
Ubuntu 9.04 has a new application that manages the notification system:
notify-osd , allowing you to display visual messages at the time you want.
Getting started
First you must install the libnotify-bin package. To do this, type in a terminal:
sudo apt-get install libnotify-bin
To see if this works, type in the terminal:
notify-send Test "This is a test"
Normally, the message "
This is a test" should be displayed
Preparing the script
Now that the software is operational,its time to create a script with the message that will be displayed at a given moment.
In your home folder, create a blank file named "
recall.sh" (the
". sh" is essential, instead of
"recall", you can put whatever you want)
In this file, write:
#!/bin/bash
notify-send "Message title" "Message"
and save.
Planning the execution of script
Now you need to run a command that will plan the display of message on-screen
Simply type in a terminal:
at -f recall.sh 19:30
This, run the script at 19:30.
If you want to run a particular day, enter:
at -f recall.sh 19:30 Jul 10
It will be displayed July 10 at 19:30
Adding an icon to the message
You will need an image or "icon" (PNG), and then edit the file recall.sh:
notify-send -i /path/of_image/image.png "Message title" "Message"