Last active
December 15, 2015 07:59
-
-
Save thameera/5228000 to your computer and use it in GitHub Desktop.
Small bash script I use to create timers from the terminal. Place it in your $PATH. When the alarm goes, a message is printed on terminal, a beep sound is played, a native notification is displayed and a message box pops up.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# USAGE | |
# timer <time> <optional message> | |
# timer 15 You've lived enough. Go die! | |
echo "Will go off in" $1 "minutes..." | |
sleep $(($1*60)) | |
shift | |
echo "Time's up!" | |
mplayer /usr/share/sounds/gnome/default/alerts/drip.ogg &>/dev/null | |
notify-send 'Timer' "$*" | |
zenity --info --title "Timer" --text "$*" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment