Add hugging others support. - annna - Annna the nice friendly bot.
 (HTM) git clone git://bitreich.org/annna/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfrinws65d7roiv6bfj7d652fid.onion/annna/
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) Tags
 (DIR) README
       ---
 (DIR) commit c77229b97a3d06a7b17fef1a4c950f2de1713069
 (DIR) parent 1635ab53222e9065727faad4231dc9e070e89414
 (HTM) Author: Annna Robert-Houdin <annna@bitreich.org>
       Date:   Thu, 29 Aug 2024 14:17:50 +0200
       
       Add hugging others support.
       
       Diffstat:
         M annna-message-common                |       8 ++++++++
       
       1 file changed, 8 insertions(+), 0 deletions(-)
       ---
 (DIR) diff --git a/annna-message-common b/annna-message-common
       @@ -1416,6 +1416,14 @@ case "${text}" in
        "${ircuser}, please hug me.")
                annna-say -s "${server}" -c "${channel}" "$(echo -e '\001')ACTION hugs ${user}$(echo -e '\001')"
                ;;
       +"${ircuser}, please hug "*" for me.")
       +        huggee="${text#* please hug }"
       +        huggee="${huggee% for me*}"
       +        if [ -n "${huggee}" ];
       +        then
       +                annna-say -s "${server}" -c "${channel}" "$(echo -e '\001')ACTION hugs ${huggee}$(echo -e '\001')"
       +        fi
       +        ;;
        "${ircuser}, how many fucks were given?")
                annna-say -s "${server}" -c "${channel}" "${user}, current fucks given: 0.0"
                ;;