diff options
author | bill-auger <mr.j.spam.me@gmail.com> | 2019-04-21 07:42:49 +0000 |
---|---|---|
committer | bill-auger <mr.j.spam.me@gmail.com> | 2019-09-25 16:02:37 -0400 |
commit | b791e3e38fbc868f523e345cfc802938de77289f (patch) | |
tree | 51dafd12dd270d66e036c0775c8b1411fa2aeca3 | |
parent | b8a24949b60fcba8dfea497e1fdb900498307d65 (diff) |
more 'hellos' and 'you got that right'
-rwxr-xr-x | labs_change_detector | 2 | ||||
-rw-r--r-- | process_event | 14 |
2 files changed, 14 insertions, 2 deletions
diff --git a/labs_change_detector b/labs_change_detector index fb8862e..c79b9f1 100755 --- a/labs_change_detector +++ b/labs_change_detector @@ -11,10 +11,12 @@ then echo "[LABS]: ERROR: cannot find the \`inotify\` program" exit elif [[ ! -d "${BOT_MAIL_DIR}" ]] +then echo "[LABS]: no such directory set in BOT_MAIL_DIR: '${BOT_MAIL_DIR}'. fail" exit fi + inotifywait -m --format '%w%f' -e create "${BOT_MAIL_DIR}" 2>/dev/null | while read email do diff --git a/process_event b/process_event index 35d0ffb..ae97b58 100644 --- a/process_event +++ b/process_event @@ -274,8 +274,18 @@ function process_event # hello # ######### - hello|hi) - send_msg "${channel_it_came_from}" "hello ${person}, it works!!!" + 'Hello' | 'Hello!' | 'Hello?' | 'Hi' | 'Hi!' | \ + 'hello' | 'hello!' | 'hello?' | 'hi' | 'hi!' ) + send_msg "${channel_it_came_from}" "Hello ${person}! Is something on your mind? Feel free to comment or ask a question at any time. Be patient if no one responds immediately. That is quite normal on the IRC. Many people will read your message when they can, and perhaps reply, if you are still in the channel." + ;; + + + ###################### + # you got that right # + ###################### + + *" that right ${my_own_name}"* ) + send_msg "${channel_it_came_from}" "You got that right, ${person}!" ;; |