[gtk-doc] common: make the logger more useful
- From: Stefan Sauer <stefkost src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk-doc] common: make the logger more useful
- Date: Fri, 12 May 2017 19:45:11 +0000 (UTC)
commit 81b969efb0b356ba464931a279ee3a21e95df6c4
Author: Stefan Sauer <ensonic users sf net>
Date: Sat Apr 29 20:37:29 2017 +0200
common: make the logger more useful
Configure the format. Make it easier to use by converting levels to upper case.
gtkdoc/common.py | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/gtkdoc/common.py b/gtkdoc/common.py
index 183c570..c46f502 100644
--- a/gtkdoc/common.py
+++ b/gtkdoc/common.py
@@ -41,7 +41,9 @@ def setup_logging():
if log_level == '':
log_level = 'INFO'
if log_level:
- logging.basicConfig(stream=sys.stdout, level=logging.getLevelName(log_level))
+ logging.basicConfig(stream=sys.stdout,
+ level=logging.getLevelName(log_level.upper()),
+
format='%(asctime)s:%(filename)s:%(funcName)s:%(lineno)d:%(levelname)s:%(message)s')
def UpdateFileIfChanged(old_file, new_file, make_backup):
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]