Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions mannaggia.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,14 @@ ndsflag=false
wallflag=false
shutdown=false
off=false
DELSTRING1="</FONT>"
DELSTRING2="</b>"
DELSTRING1=" <FONT SIZE=\"-1\">|<b>|</b>|</FONT>"
DEFPLAYER="mplayer -cache 1024 -"
PLAYER="${PLAYER:-$DEFPLAYER}"
LC_CTYPE=C

say() {
local IFS=+
mplayer -ao alsa -really-quiet -noconsolecontrols "http://translate.google.com/translate_tts?ie=UTF-8&client=tw-ob&q=$*&tl=it"
mplayer -really-quiet -noconsolecontrols "http://translate.google.com/translate_tts?ie=UTF-8&client=tw-ob&q=$*&tl=it"
}

if [ $(uname) = "Darwin" ]
Expand Down Expand Up @@ -126,7 +125,8 @@ fi
while [ "$nds" != 0 ]
do
# shellcheck disable=SC2019
MANNAGGIA="Mannaggia $(curl -s "www.santiebeati.it/$(</dev/urandom tr -dc A-Z|head -c1)/"|grep -a tit|cut -d'>' -f 4-9| sed '/^.$/d' | $shufCmd -n1 |awk -F "$DELSTRING1" '{print$1$2}'|awk -F "$DELSTRING2" '{print$1}' | iconv -f ISO-8859-1)"
MANNAGGIA="Mannaggia $(curl -s "https://www.santiebeati.it/$(</dev/urandom tr -dc A-Z|head -c1)/"|grep -aI tit|cut -d'>' -f 3-9| sed '/^.$/d' | grep -vsI '</A>' | $shufCmd -n1 |awk -F "$DELSTRING1" '{print$1$2" "$3$4}' | iconv -f ISO-8859-1)"

if [ "$wallflag" = true ]
then
pot=$(( nds % 50 ))
Expand Down