2017-04-06 21:18:52 -04:00
|
|
|
[ -f functions.sh ] && source functions.sh
|
|
|
|
|
2017-05-20 11:10:07 -04:00
|
|
|
joke="$(curl -s --connect-timeout 5 'https://thatsagooden.tk/?api=txt&type=all&exclude=sex,little_johnny')"
|
2017-04-11 21:27:29 -04:00
|
|
|
joke="${joke//[[:space:]]/ }"
|
2017-05-20 11:10:07 -04:00
|
|
|
[ -n "$joke" ] && msg "$2" "$joke" || msg "$2" "No jokes found."
|