2016-09-24 16:19:52 -04:00
|
|
|
[ -f functions.sh ] && source functions.sh
|
|
|
|
|
2020-08-10 18:24:05 -04:00
|
|
|
set -f
|
2016-09-24 16:19:52 -04:00
|
|
|
quote="$(curl -s http://bash.org/?random)"
|
|
|
|
quote="$(echo "$quote" | grep -m 1 -A 10 '"Permanent link to this quote."')"
|
|
|
|
quote="${quote#*class=\"qt\">}"
|
|
|
|
quote="${quote//</<}"
|
|
|
|
quote="${quote//>/>}"
|
2016-09-24 23:09:37 -04:00
|
|
|
quote="${quote%%<p class*}"
|
2020-08-10 07:36:22 -04:00
|
|
|
quote="$(echo "$quote" | pandoc -t plain)"
|
2020-08-10 18:24:05 -04:00
|
|
|
msg "$2" "$(echo "$quote" | tr -cd '[:print:]')"
|
|
|
|
set +f
|