summaryrefslogtreecommitdiffstats
path: root/todo.py
diff options
context:
space:
mode:
authorMatt Wilson <msw@redhat.com>1999-09-23 15:52:38 +0000
committerMatt Wilson <msw@redhat.com>1999-09-23 15:52:38 +0000
commita146a31ce9bbb8c6b5ca808edb08a1340b395e4d (patch)
tree0d43ea0a6d7e83590e164e89dd36dcb6355e0aa8 /todo.py
parent52c06008daa99a085b993c42d085069918c9db5f (diff)
downloadanaconda-a146a31ce9bbb8c6b5ca808edb08a1340b395e4d.tar.gz
anaconda-a146a31ce9bbb8c6b5ca808edb08a1340b395e4d.tar.xz
anaconda-a146a31ce9bbb8c6b5ca808edb08a1340b395e4d.zip
only display formatting window if we actually have formatting to do
Diffstat (limited to 'todo.py')
-rw-r--r--todo.py11
1 files changed, 8 insertions, 3 deletions
diff --git a/todo.py b/todo.py
index bb8b722f5..8de1020c5 100644
--- a/todo.py
+++ b/todo.py
@@ -589,10 +589,11 @@ class ToDo:
for mntpoint in keys:
(device, fsystem, format) = self.mounts[mntpoint]
if not format: continue
- w = self.intf.waitWindow(_("Formatting"),
- _("Formatting %s filesystem...") % (mntpoint,))
isys.makeDevInode(device, '/tmp/' + device)
if fsystem == "ext2" and createFs:
+ w = self.intf.waitWindow(_("Formatting"),
+ _("Formatting %s filesystem...") % (mntpoint,))
+
args = [ "mke2fs", '/tmp/' + device ]
# set up raid options for md devices.
if device[:2] == 'md':
@@ -613,7 +614,11 @@ class ToDo:
args,
stdout = "/dev/tty5", stderr = "/dev/tty5",
searchPath = 1)
+ w.pop()
elif fsystem == "swap" and createSwap:
+ w = self.intf.waitWindow(_("Formatting"),
+ _("Formatting %s filesystem...") % (mntpoint,))
+
rc = iutil.execWithRedirect ("/usr/sbin/mkswap",
[ "mkswap", '-v1', '/tmp/' + device ],
stdout = None, stderr = None,
@@ -621,11 +626,11 @@ class ToDo:
if rc:
raise RuntimeError, "error making swap on " + device
isys.swapon ('/tmp/' + device)
+ w.pop()
else:
pass
os.remove('/tmp/' + device)
- w.pop()
if createFs:
self.madeFilesystems = 1