diff --git a/boswatch.py b/boswatch.py index 13f1f29..e207102 100755 --- a/boswatch.py +++ b/boswatch.py @@ -151,6 +151,8 @@ try: # For debug display/log args # try: + logging.debug("SW Version: %s",globals.getVers("vers")) + logging.debug("Build Date: %s",globals.getVers("date")) logging.debug("BOSWatch given arguments") if args.test: logging.debug(" - Test-Mode!") diff --git a/includes/globals.py b/includes/globals.py index f4ab2d8..269dc6f 100644 --- a/includes/globals.py +++ b/includes/globals.py @@ -25,4 +25,12 @@ filterList = [] # idDescribing fmsDescribtionList = {} zveiDescribtionList = {} -ricDescribtionList = {} \ No newline at end of file +ricDescribtionList = {} + +# returns the Version number +# function -> read only in script +def getVers(mode="vers"): + if mode == "vers": + return "2.0-RC" + elif mode == "date": + return " 2015/07/02" \ No newline at end of file diff --git a/includes/shellHeader.py b/includes/shellHeader.py index 7137c41..b13d909 100644 --- a/includes/shellHeader.py +++ b/includes/shellHeader.py @@ -10,6 +10,8 @@ Shows the header in shell if quiet mode is not active @requires: none """ +from includes import globals + def printHeader(args): """ Prints the header to the shell @@ -20,14 +22,17 @@ def printHeader(args): @return: nothing """ try: - print " ____ ____ ______ __ __ __ " - print " / __ )/ __ \/ ___/ | / /___ _/ /______/ /_ b" - print " / __ / / / /\__ \| | /| / / __ `/ __/ ___/ __ \ e" - print " / /_/ / /_/ /___/ /| |/ |/ / /_/ / /_/ /__/ / / / t" - print " /_____/\____//____/ |__/|__/\__,_/\__/\___/_/ /_/ a" - print " German BOS Information Script " - print " by Bastian Schroll, Jens Herrmann " + print " ____ ____ ______ __ __ __ " + print " / __ )/ __ \/ ___/ | / /___ _/ /______/ /_ " + print " / __ / / / /\__ \| | /| / / __ `/ __/ ___/ __ \ " + print " / /_/ / /_/ /___/ /| |/ |/ / /_/ / /_/ /__/ / / / " + print " /_____/\____//____/ |__/|__/\__,_/\__/\___/_/ /_/ " + print " German BOS Information Script " + print " by Bastian Schroll, Jens Herrmann " print "" + print "SW Version: "+globals.getVers("vers") + print "Build Date: "+globals.getVers("date") + print "" print "Frequency: "+args.freq print "Device-ID: "+str(args.device)