Added color and style consistency to /status log messages

pull/14/head
Aaron Johnson 6 years ago
parent 69381daf66
commit ac47bcf4f3

@ -74,10 +74,10 @@ def process_command_srvstatus(message, command, adm)
print 'Checking connectivity to Empyrion service... ' print 'Checking connectivity to Empyrion service... '
STDOUT.flush STDOUT.flush
if system("nc -zvw3 #{telnet['host']} #{telnet['port']} >/dev/null 2>&1") if system("nc -zvw3 #{telnet['host']} #{telnet['port']} >/dev/null 2>&1")
print "Server responded!\nSending message receipt... " print "OK\n".green.bold + "Sending message receipt... "
STDOUT.flush STDOUT.flush
if `./scripts/srvstatus.receipt #{@conf['token']} #{message.chat.id}` if `./scripts/srvstatus.receipt #{@conf['token']} #{message.chat.id}`
print "Receipt sent!\nFetching details...\n" print "OK\n".green.bold + "Fetching details...\n"
else else
print "Receipt FAILED to send (non-zero exit code on scripts/srvstatus.receipt) !!!\nContinuing to fetch details anyway...\n".red.bold print "Receipt FAILED to send (non-zero exit code on scripts/srvstatus.receipt) !!!\nContinuing to fetch details anyway...\n".red.bold
end end

Loading…
Cancel
Save