mirror of
git://git.yoctoproject.org/poky.git
synced 2025-07-19 21:09:03 +02:00

Add a '\n' to the last line of the file to fix: No newline at end of file (Bitbake rev: 54f1359ed2e9d47980cd221b7b43ef56543fe06d) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
15 lines
422 B
Python
15 lines
422 B
Python
__version__ = "1.0.0"
|
|
|
|
import os, time
|
|
import sys,logging
|
|
|
|
def init_logger(logfile, loglevel):
|
|
numeric_level = getattr(logging, loglevel.upper(), None)
|
|
if not isinstance(numeric_level, int):
|
|
raise ValueError('Invalid log level: %s' % loglevel)
|
|
FORMAT = '%(asctime)-15s %(message)s'
|
|
logging.basicConfig(level=numeric_level, filename=logfile, format=FORMAT)
|
|
|
|
class NotFoundError(Exception):
|
|
pass
|