moar fixes
This commit is contained in:
parent
739072bd39
commit
9b042633f9
1 changed files with 10 additions and 2 deletions
12
cloudbot
12
cloudbot
|
@ -27,9 +27,17 @@ clearlog1 = ": > ./bot.log && "
|
||||||
clearlog2 = ": > ./bot.log"
|
clearlog2 = ": > ./bot.log"
|
||||||
command = ":"
|
command = ":"
|
||||||
|
|
||||||
daemoncheck = subprocess.check_output("locate /usr/bin/daemon", shell=True)
|
try:
|
||||||
|
daemoncheck = subprocess.check_output("locate /usr/bin/daemon", shell=True)
|
||||||
|
except (subprocess.CalledProcessError), e:
|
||||||
|
print "daemon not installed!"
|
||||||
|
exit
|
||||||
daemon = re.match(r'^/usr/bin/daemon$', daemoncheck)
|
daemon = re.match(r'^/usr/bin/daemon$', daemoncheck)
|
||||||
screencheck = subprocess.check_output("locate /usr/bin/screen", shell=True)
|
try:
|
||||||
|
screencheck = subprocess.check_output("locate /usr/bin/screen", shell=True)
|
||||||
|
except (subprocess.CalledProcessError), e:
|
||||||
|
print "screen not installed!"
|
||||||
|
exit
|
||||||
screen = re.match(r'^/usr/bin/screen$', screencheck)
|
screen = re.match(r'^/usr/bin/screen$', screencheck)
|
||||||
if os.path.isfile("./config"):
|
if os.path.isfile("./config"):
|
||||||
backend = config.get("wrapper", {}).get("backend", "daemon")
|
backend = config.get("wrapper", {}).get("backend", "daemon")
|
||||||
|
|
Reference in a new issue