(re-)structure code - use include-files now

- move gobals and other stuff to includes
- extract code from boswatch.py to include-files

bugfix in BosMon-plugin
This commit is contained in:
JHCD 2015-05-22 16:44:23 +02:00
parent c296af22b0
commit e67a357d8e
15 changed files with 243 additions and 196 deletions

View file

@ -1,9 +1,6 @@
#!/usr/bin/python
# -*- coding: cp1252 -*-
import logging # Global logger
import globals # Global variables
#########
# USAGE
#
@ -23,6 +20,11 @@ import globals # Global variables
# usable Loglevels debug|info|warning|error|exception|critical
# if you use .exception in Try:Exception: Construct, it logs the Python EX.message too
import logging # Global logger
from includes import globals # Global variables
def run(typ,freq,data):
try:
#ConfigParser
@ -45,4 +47,4 @@ def run(typ,freq,data):
########## User Plugin CODE ##########
except:
logging.exception("unknown error")
logging.exception("unknown error")