Register
It is currently Wed Apr 23, 2014 1:30 pm

Remind Me : a bashrc script


All times are UTC - 6 hours


Post new topic Reply to topic  [ 4 posts ] 
Author Message
 PostPosted: Thu Jun 19, 2008 11:10 pm   
Site Admin
User avatar

Joined: Sun May 15, 2005 9:36 pm
Posts: 657
Location: Des Moines, Iowa
Remind Me : a bashrc script
Shamelessly stolen from an ArchLinux.org post ;)

Code:
# remind me, its important!
# usage: remindme <time> <text>
# e.g.: remindme 10m "omg, the pizza"
function remindme()
{
    sleep $1 && zenity --info --text "$2" &
}


Top
 Profile WWW  
 PostPosted: Fri Jun 20, 2008 10:42 am   

Joined: Tue Apr 01, 2008 10:19 am
Posts: 49
For repeating reminders, I use a cronjob.
Code:
45 18 * * 3 $HOME/bin/othremind

Code:
#!/bin/bash

export DISPLAY=':0.0'
summary="                       Radio time!"
message="
  Off the Hook will be starting soon, at 19:00."
icon="${HOME}/stuff/oth_icon.gif"


notify-send -t 0 -i "$icon" "$summary" "$message"


Top
 Profile  
 PostPosted: Fri Jun 20, 2008 11:18 am   
User avatar

Joined: Sun Apr 13, 2008 4:05 am
Posts: 37
Location: /dev/random
crouse wrote:
Remind Me : a bashrc script
Shamelessly stolen from an ArchLinux.org post ;)

Code:
# remind me, its important!
# usage: remindme <time> <text>
# e.g.: remindme 10m "omg, the pizza"
function remindme()
{
    sleep $1 && zenity --info --text "$2" &
}


love it.


Top
 Profile  
 PostPosted: Fri Jun 20, 2008 9:34 pm   
Site Admin
User avatar

Joined: Sun May 15, 2005 9:36 pm
Posts: 657
Location: Des Moines, Iowa
Daenyth wrote:
For repeating reminders, I use a cronjob.
Code:
45 18 * * 3 $HOME/bin/othremind

Code:
#!/bin/bash

export DISPLAY=':0.0'
summary="                       Radio time!"
message="
  Off the Hook will be starting soon, at 19:00."
icon="${HOME}/stuff/oth_icon.gif"


notify-send -t 0 -i "$icon" "$summary" "$message"



hmmmmm I should do that too :) Good idea !


Top
 Profile WWW  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  


BashScripts | Promote Your Page Too
Powered by phpBB © 2011 phpBB Group
© 2003 - 2011 USA LINUX USERS GROUP