summaryrefslogtreecommitdiff
path: root/DistUpgrade
diff options
context:
space:
mode:
authorMichael Vogt <egon@top>2005-12-06 15:16:44 +0100
committerMichael Vogt <egon@top>2005-12-06 15:16:44 +0100
commit0fe72e8bb3cd2fe424fdfaddabde7ed395252b36 (patch)
tree67d598a58b97ee8f40297e4042b1734f14b6a1b1 /DistUpgrade
parentdf65ecf7bd6e7e24f8aa9640fc0e33ef6554ef82 (diff)
downloadpython-apt-0fe72e8bb3cd2fe424fdfaddabde7ed395252b36.tar.gz
* added the missing bits, can do a complete upgrade now! butt ugly though :/
Diffstat (limited to 'DistUpgrade')
-rw-r--r--DistUpgrade/DistUpgrade.py29
-rw-r--r--DistUpgrade/data/breezy-rm.whitelist25
2 files changed, 49 insertions, 5 deletions
diff --git a/DistUpgrade/DistUpgrade.py b/DistUpgrade/DistUpgrade.py
index 96dd91a4..968e43b7 100644
--- a/DistUpgrade/DistUpgrade.py
+++ b/DistUpgrade/DistUpgrade.py
@@ -266,12 +266,29 @@ class DistUpgradeControler(object):
progress = self._view.getFetchProgress()
self._cache.update(progress)
- def doDistUpgrade(self):
+ def askDistUpgrade(self):
self._cache.upgrade(True)
changes = self._cache.getChanges()
res = self._view.confirmChanges(changes,self._cache.requiredDownload)
return res
+ def doDistUpgrade(self):
+ fprogress = self._view.getFetchProgress()
+ iprogress = self._view.getInstallProgress()
+ self._cache.commit(fprogress,iprogress)
+
+ def doPostUpgrade(self):
+ # FIXME: check out what packages are cruft now
+ pass
+
+ def askForReboot(self):
+ return self._view.askYesNoQuestion(_("Reboot required"),
+ _("The upgrade is finished now. "
+ "A reboot is required to "
+ "now, do you want to do this "
+ "now?"))
+
+ # this is the core
def breezyUpgrade(self):
# sanity check (check for ubuntu-desktop, brokenCache etc)
self._view.updateStatus(_("Checking the system"))
@@ -294,15 +311,17 @@ class DistUpgradeControler(object):
# calc the dist-upgrade and see if the removals are ok/expected
# do the dist-upgrade
- if not self.doDistUpgrade():
+ if not self.askDistUpgrade():
sys.exit(1)
-
-
+ self.doDistUpgrade()
+
# do post-upgrade stuff
+ self.doPostUpgrade()
# done, ask for reboot
+ if self.askForReboot():
+ subprocess.call(["reboot"])
-
def run(self):
self.breezyUpgrade()
diff --git a/DistUpgrade/data/breezy-rm.whitelist b/DistUpgrade/data/breezy-rm.whitelist
new file mode 100644
index 00000000..cd5d6d0b
--- /dev/null
+++ b/DistUpgrade/data/breezy-rm.whitelist
@@ -0,0 +1,25 @@
+# this is a list of removals (and their reason) for a hoary->breezy update
+#
+aspell-bin # merged back into aspell pkg
+capplets # replaced by gnome-control-center
+dbus-1 # " by libdbus-1
+dbus-glib-1 # " by libdbus-glib-1-1
+libcamel1.2-3 # " by libcamel1.2-6
+libebook1.2-3 # " by libebook1.2-5
+libedataserverui1.2-4 # " by libedataserverui1.2-6
+libgc1 # " by libgc1c2
+libhal-storage0 # " by libhal-storage1
+libhal0 # " by libhal1
+libid3-3.8.3 # " by libid3-3.8.3c2
+libmusicbrainz2 # " by libmusicbrainz2c2
+libmusicbrainz4 # " by libmusicbrainz4c2
+libnautilus-burn1 # " by libnautilus-burn2
+libostyle1 # " by libostyle1c2
+libpt-1.8.3 # " by libpt-1.8.3c2
+libsmpeg0 # " by libsmpeg0c2
+libsp1 # " by libsp1c2
+postfix-tls # postfix provides this now
+ubuntu-quickguide # not updated to breezy
+xlibmesa-dri # replaced by libgl1-mesa-dri
+xlibmesa-gl # " by libgl1-mesa
+xlibmesa-glu # " by libglu1-mesa