[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
[PATCH] Do not write "Running..." to stdout, as that could be tty1.
- From: Chris Lumens <clumens redhat com>
- To: anaconda-devel-list redhat com
- Cc:
- Subject: [PATCH] Do not write "Running..." to stdout, as that could be tty1.
- Date: Thu, 12 Mar 2009 10:31:12 -0400
Doing so sends a whole lot of spew to tty1 which not only looks bad, but
makes VNC and text installs look even worse than they already are. Also,
let's write output from execWithPulseProgress to the program.log too.
---
iutil.py | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/iutil.py b/iutil.py
index d9e8a77..221504f 100644
--- a/iutil.py
+++ b/iutil.py
@@ -80,7 +80,6 @@ def execWithRedirect(command, argv, stdin = None, stdout = None,
runningLog = open("/tmp/program.log", "a")
runningLog.write("Running... %s\n" % ([command] + argv,))
- os.write(stdout, "Running... %s\n" %([command] + argv,))
try:
proc = subprocess.Popen([command] + argv, stdin=stdin,
@@ -197,7 +196,8 @@ def execWithPulseProgress(command, argv, stdin = None, stdout = None,
elif stderr is None or not isinstance(stderr, file):
stderr = sys.stderr.fileno()
- os.write(stdout, "Running... %s\n" %([command] + argv,))
+ runningLog = open("/tmp/program.log", "a")
+ runningLog.write("Running... %s\n" % ([command] + argv,))
p = os.pipe()
childpid = os.fork()
@@ -224,6 +224,7 @@ def execWithPulseProgress(command, argv, stdin = None, stdout = None,
raise IOError, args
os.write(stdout, s)
+ runningLog.write(s)
if progress: progress.pulse()
if len(s) < 1:
--
1.6.1.3
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]