This commit is contained in:
neersighted 2012-02-29 19:57:34 -08:00
parent 676222b5f9
commit 2839bc3167

View file

@ -11,8 +11,8 @@ if os.path.isfile("./config"):
config = json.load(open('config')) config = json.load(open('config'))
except ValueError, e: except ValueError, e:
print 'error: malformed config', e print 'error: malformed config', e
else: else:
config = False config = False
nocol = "\033[1;m" nocol = "\033[1;m"
red = "\033[1;31m" red = "\033[1;31m"
@ -29,14 +29,14 @@ command = ":"
try: try:
daemoncheck = subprocess.check_output("locate /usr/bin/daemon", shell=True) daemoncheck = subprocess.check_output("locate /usr/bin/daemon", shell=True)
except (subprocess.CalledProcessError), e: except (subprocess.CalledProcessError), e:
daemoncheck = False daemoncheck = "False"
print "daemon not installed!" print "daemon not installed!"
exit exit
daemon = re.match(r'^/usr/bin/daemon$', daemoncheck) daemon = re.match(r'^/usr/bin/daemon$', daemoncheck)
try: try:
screencheck = subprocess.check_output("locate /usr/bin/screen", shell=True) screencheck = subprocess.check_output("locate /usr/bin/screen", shell=True)
except (subprocess.CalledProcessError), e: except (subprocess.CalledProcessError), e:
screencheck = False screencheck = "False"
print "screen not installed!" print "screen not installed!"
exit exit
screen = re.match(r'^/usr/bin/screen$', screencheck) screen = re.match(r'^/usr/bin/screen$', screencheck)