diff --git a/commands.rb b/commands.rb index b401f68..5552dd1 100644 --- a/commands.rb +++ b/commands.rb @@ -27,8 +27,9 @@ end def process_command_start(message, command, adm) reply = "I am #{@botname}, and I am here to provide temperature information from various sensors. Currently I can retrieve information " + - "from temperature sensors as well as report when temperatures are out of a specified range.\n\n" + - "Commands available:\n/start (Shows this message)\n/check or /c (Show temperatures)\n/report or /r (Show all temperatures)\n/whoami or /chatinfo (Provides IDs for internal use)\n/whereareyou or /location (Provides hostname for bot server)\n\n" + + "from temperature sensors. In a future version, I will also report when temperatures are out of a specified range through regular checks.\n\n" + + "Commands available:\n/start (Shows this message)\n/check or /c (Show a specific temperature interactively)\n/report or /r (Show all temperatures)\n" + + "/simple or /s (Show a simplified report)\n\nExtra functions:\n/whoami or /chatinfo (Provides IDs for internal use)\n/whereareyou or /location (Provides hostname for bot server)\n\n" + "Check again later to see if any new functions have been added, or use /patchnotes to learn about recent updates.\n" + "You can also view the source code at the following location:\nhttps://git.skyfall.tech/skyfall/heatbot" if message_from_admin?(message, adm) @@ -51,7 +52,7 @@ end def process_command_patchnotes(message, command, adm) if is_chat_authorized?(message, @auth_chat) || message_from_admin?(message, adm) - reply = File.read(static_text/patchnotes.txt) + reply = File.read("static_text/patchnotes.txt") else reply = "I am not authorized to provide this information here." end @@ -60,7 +61,7 @@ end def process_command_location(message, command, adm) if message_from_admin?(message, adm) || is_chat_authorized?(message, @auth_chat) - reply = "I am currently located at:\n\nHost: #{`head -n1 /etc/hostname`}ExtIP: #{`curl icanhazip.com 2>/dev/null`}" + reply = "I am currently located at:\n\nHost: #{`head -n1 /etc/hostname`}ExtIP: #{`curl #{@ip_provider} 2>/dev/null`}" else reply = "I am not authorized to provide this information here." end diff --git a/run.rb b/run.rb index 925f221..fa6c463 100755 --- a/run.rb +++ b/run.rb @@ -25,10 +25,9 @@ admin = @conf['admin'] @tunit = @conf['units'] ## Non-configurable -#@simplehot = 75 -#@simplecold = 50 @simplehot = 24 @simplecold = 10 +@ip_provider = "ip.skyfall.tech" ### Begin sanity check ### STDOUT.sync = true diff --git a/static_text/patchnotes.txt b/static_text/patchnotes.txt index a23f5e2..0b43997 100644 --- a/static_text/patchnotes.txt +++ b/static_text/patchnotes.txt @@ -2,4 +2,4 @@ SkyfallTech HeatBot Patch Notes: v0.1.00 -+ Starting from a fork of the Skyfall EGS-Bot v0.4.00 ++ Initial Release