Include date in log messages

This commit is contained in:
Stefan Bethke 2017-09-18 11:03:19 +02:00
parent 1f508f9b27
commit e726390c5f

View file

@ -544,7 +544,7 @@ def main():
os.chdir(os.path.expanduser("~/.tivo"))
handler = logging.handlers.RotatingFileHandler("tivomirror.log", maxBytes=2*1024*1024, backupCount=5)
handler.setFormatter(logging.Formatter(fmt='tivomirror[{}] %(asctime)s %(levelname)6.6s %(message)s'.format(os.getpid()),
datefmt='%H:%M:%S'))
datefmt='%d-%m %H:%M:%S'))
logger.addHandler(handler)
downloaddb = anydbm.open("downloads.db", "c")
toc = TivoToc()