Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/sugar/logger.py
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <mpg@redhat.com>2007-10-09 19:50:48 (GMT)
committer Marco Pesenti Gritti <mpg@redhat.com>2007-10-09 19:50:48 (GMT)
commit2a47190f283d6411ed5bc9211da2abd521bb3cd8 (patch)
tree14d8a351b1b984b95d3f87f4457fab08c196c0da /sugar/logger.py
parent56ecabbd78df97fd9d548d7642756a8c9a19e3ff (diff)
When running from a terminal don't use logs.
Diffstat (limited to 'sugar/logger.py')
-rw-r--r--sugar/logger.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/sugar/logger.py b/sugar/logger.py
index 43d0d76..26b03ac 100644
--- a/sugar/logger.py
+++ b/sugar/logger.py
@@ -44,7 +44,7 @@ def start(log_filename=None):
if os.environ.has_key('SUGAR_LOGGER_LEVEL'):
set_level(os.environ['SUGAR_LOGGER_LEVEL'])
- if log_filename:
+ if log_filename and not sys.stdin.isatty():
log_path = os.path.join(get_logs_dir(), log_filename + '.log')
log_file = open(log_path, 'w')