Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- function finish()
- {
- exit $?
- }
- while getopts ":t:u:" FLAG; do
- case $FLAG in
- t) #set option "a"
- TIME=$OPTARG
- ;;
- esac
- LOOP=1
- done
- shift $((OPTIND-1))
- function finish()
- {
- exit $?
- }
- while :;do
- notify-send --icon=/usr/share/pixmaps/pinkie.png --urgency=low "Pinkie Pie Says" "$(fortune -e $@|recode ascii..html)"
- if [ -z $LOOP ];then
- break
- fi
- sleep $TIME
- done
- trap finish SIGINT SIGHUP SIGTERM
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement