From d03f6b63c6f6f02700c12b8dd2ff9c72e1655def Mon Sep 17 00:00:00 2001 From: Luke Rogers Date: Sun, 1 Apr 2012 22:58:14 +1200 Subject: [PATCH] A few tweaks to system.py --- plugins/system.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/plugins/system.py b/plugins/system.py index f67b16d..e575acd 100755 --- a/plugins/system.py +++ b/plugins/system.py @@ -1,4 +1,5 @@ # Plugin by Lukeroge, and neersighted +# Yeah, the code in this sucks. Meh. import os import re import time @@ -26,12 +27,15 @@ def checkProc(checked_stats): @hook.command(autohelp=False) def system(inp): ".system -- Retrieves information about the host system." - name = platform.node() + hostname = platform.node() os = platform.platform() - python_version = platform.python_implementation() + ' ' + platform.python_version() - arch = '-'.join(platform.architecture()) + python_imp = platform.python_implementation() + python_ver = platform.python_version() + architecture = '-'.join(platform.architecture()) cpu = platform.machine() - return 'Name: \x02%s\x02, Operating System: \x02%s\x02, Python Version: \x02%s\x02, Architecture: \x02%s\x02, CPU: \x02%s\x02' % (name, os, python_version, arch, cpu) + return 'Hostname: \x02%s\x02, Operating System: \x02%s\x02, Python Version:' \ + ' \x02%s %s\x02, Architecture: \x02%s\x02, CPU: \x02%s\x02' % (hostname, + os, python_imp, python_ver, architecture, cpu) @hook.command(autohelp=False)