Logging toegevoegd
This commit is contained in:
@@ -3,9 +3,11 @@
|
||||
import sys
|
||||
import getopt
|
||||
import argparse
|
||||
import logging
|
||||
from lmwsip import LmwSip
|
||||
|
||||
def run(args):
|
||||
logging.basicConfig(level=args.debug)
|
||||
try:
|
||||
lmwsip = LmwSip(host=args.host, port=args.port,
|
||||
ssl=not args.unencrypted,
|
||||
@@ -43,6 +45,9 @@ def main():
|
||||
parser.add_argument("-t", "--time", action='store',
|
||||
default=lastTime["time_of_day"],
|
||||
help="Time replacement string [HH:MM]")
|
||||
parser.add_argument("-D", "--debug", action='store',
|
||||
default="WARN",
|
||||
help="Debug level")
|
||||
parser.add_argument("files", type=argparse.FileType('r'), nargs="+",
|
||||
help="Sip files to run")
|
||||
run(parser.parse_args())
|
||||
|
Reference in New Issue
Block a user