diff options
author | Joe <joe@joelightning.com> | 2011-11-10 21:02:07 +0000 |
---|---|---|
committer | Joe <joe@joelightning.com> | 2011-11-10 21:02:07 +0000 |
commit | 18d8ef4ef0638fd445e65a61414e3d85d608d84d (patch) | |
tree | d82df88b50c6915a2bc97bc8f8970c0d0a384bfc /hack_of_all_hacks | |
parent | ede41b6a15ac8d14823b161353fee2253298874b (diff) |
improved it
Diffstat (limited to 'hack_of_all_hacks')
-rw-r--r-- | hack_of_all_hacks | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/hack_of_all_hacks b/hack_of_all_hacks index 1e42457..6c52356 100644 --- a/hack_of_all_hacks +++ b/hack_of_all_hacks @@ -137,15 +137,15 @@ EOF ##################### # If pbot is present record it. - [[ ${sender%%!*} == pbot ]] && touch pbot_present + [[ ${sender%%!*} == pbot ]] && echo yes > pbot_present - # If pbot is not present. - if ! [[ -f pbot_present ]] + if [[ ${line} =~ http://[^\ ]+ ]] || [[ ${line} =~ https://[^\ ]+ ]] then - if [[ ${line} =~ http://[^\ ]+ ]] || [[ ${line} =~ https://[^\ ]+ ]] - then - url_to_get="${BASH_REMATCH}" + url_to_get="${BASH_REMATCH}" + # If pbot is not present. + if grep no pbot_present + then the_title=$( curl -L --compressed "${url_to_get}" 2> /dev/null | while rdom @@ -163,7 +163,7 @@ EOF fi fi fi - + # TODO: add a birthday announcement feature, cointoss feature, timer # feature. |