Introduction
Introduction Statistics Contact Development Disclaimer Help
Add a way to stop the last emoji prompt. - annna - Annna the nice friendly bot.
git clone git://bitreich.org/annna/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfrinws6…
Log
Files
Refs
Tags
README
---
commit 20c8c162b764e43f8e68c2c4d8cdaf324b13c91f
parent 74e020ed7d8b6f0ed3436250d9129d2e14c82c25
Author: Annna Robert-Houdin <[email protected]>
Date: Sun, 25 Feb 2024 10:47:57 +0100
Add a way to stop the last emoji prompt.
Thanks ggg for the suggestion!
Diffstat:
M annna-message-common | 10 ++++++++++
M stable-diffusion-emoji | 11 +++++++++--
2 files changed, 19 insertions(+), 2 deletions(-)
---
diff --git a/annna-message-common b/annna-message-common
@@ -362,6 +362,16 @@ case "${text}" in
annna-say -s "${server}" -c "${channel}" "${user}, ${upcuri}"
fi
;;
+"${ircuser}, please stop the last emoji prompt.")
+ lastemojipromptpid="$(pgrep -f stable-diffusion-emoji | sort -n | tail…
+ if [ -n "${lastemojipromptpid}" ];
+ then
+ pstree -A -p "${lastemojipromptpid}" | grep -Eow "[0-9]+" | xa…
+ annna-say -s "${server}" -c "${channel}" "${user}, I HUPed ${l…
+ else
+ annna-say -s "${server}" -c "${channel}" "${user}, sorry, no i…
+ fi
+ ;;
"${ircuser}, play despacito plz.")
annna-say -s "${server}" -c "${channel}" "${user}, gophers://bitreich.…
;;
diff --git a/stable-diffusion-emoji b/stable-diffusion-emoji
@@ -27,7 +27,14 @@ if [ ! -e "${emojidb}/${emojifile}" ];
then
SD_MODEL="/br/ai/stable-diffusion.cpp/models/epicphotogasm_x-ggml-mode…
stable-diffusion "${emojidb}/${emojifile}" "${emojiprompt}"
- printf "%s\n" "${emojiprompt}" >> "${emojidb}/${emojiorig}"
+ if [ -e "${emojidb}/${emojifile}" ];
+ then
+ printf "%s\n" "${emojiprompt}" >> "${emojidb}/${emojiorig}"
+ fi
fi
-[ $? -eq 0 ] && printf "%s/%s\n" "${emojiuribase}" "${emojifile}"
+if [ -e "${emojidb}/${emojifile}" ];
+then
+ printf "%s/%s\n" "${emojiuribase}" "${emojifile}"
+fi
+
You are viewing proxied material from bitreich.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.