From 0af5e374019036091acb0887d8b7041eaed26113 Mon Sep 17 00:00:00 2001 From: Frederic Massart Date: Mon, 6 Aug 2012 15:55:49 +0800 Subject: [PATCH] Flushes the output buffer after each echo --- lib/tools.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/tools.py b/lib/tools.py index 2db224b..7c3ede4 100644 --- a/lib/tools.py +++ b/lib/tools.py @@ -3,6 +3,7 @@ import shlex import subprocess +import sys def yesOrNo(q): answers = ['y', 'n'] @@ -15,6 +16,7 @@ def yesOrNo(q): def debug(str): print str + sys.stdout.flush() def process(cmd, cwd=None, stdout=subprocess.PIPE, stderr=subprocess.PIPE): if type(cmd) != 'list': -- 2.11.0