diff options
| author | Sebastian Heinlein <sebi@sebi-laptop> | 2006-11-25 09:55:04 +0100 |
|---|---|---|
| committer | Sebastian Heinlein <sebi@sebi-laptop> | 2006-11-25 09:55:04 +0100 |
| commit | d21a4328a369e521c49a7ba21834b3e5e950ca97 (patch) | |
| tree | 08f192dfcf3480101cc7e7f923d0fb05876dbde8 /DistUpgrade | |
| parent | ee8317343ad726571d5f6ad863ee0b27d58251e5 (diff) | |
| download | python-apt-d21a4328a369e521c49a7ba21834b3e5e950ca97.tar.gz | |
* Fork a pyton-aptsources source tree from update-manager
Diffstat (limited to 'DistUpgrade')
26 files changed, 0 insertions, 5203 deletions
diff --git a/DistUpgrade/Changelog b/DistUpgrade/Changelog deleted file mode 100644 index 46e6fb89..00000000 --- a/DistUpgrade/Changelog +++ /dev/null @@ -1,150 +0,0 @@ -2006-10-28: - - catch errors when load_icon() does not work -2006-10-27: - - reset self.read so that we do not loop endlessly when dpkg - sends unexpected data (lp: #68553) -2006-10-26: - - make sure that xserver-xorg-video-all get installed if - xserver-xorg-driver-all was installed before (lp: #58424) -2006-10-21: - - comment out old cdrom sources - - demotions updated -2006-10-21: - - fix incorrect arguments in fixup logging (lp: #67311) - - more error logging - - fix upgrade problems for people with unofficial compiz - repositories (lp: #58424) - - rosetta i18n updates - - uploaded -2006-10-17: - - ensure bzr, tomboy and xserver-xorg-input-* are properly - upgraded - - don't fail if dpkg sents unexpected status lines (lp: #66013) -2006-10-16: - - remove leftover references to ubuntu-base and - use ubuntu-minimal and ubuntu-standard instead - - updated translations from rosetta -2006-10-13: - - log held-back as well -2006-10-12: - - check if cdrom.lst actually exists before copying it -2006-10-11: - - keep pixbuf loader reference around so that we - have one after the upgrade when the old - /usr/lib/gtk-2.0/loader/2.4.0/ loader is gone. - This fixes the problem of missing stock-icons - after the upgrade. Also revalidate the theme - in each step. -2006-10-10: - - fix time calculation - - fix kubuntu upgrade case -2006-10-06: - - fix source.list rewrite corner case bug (#64159) -2006-10-04: - - improve the space checking/logging -2006-09-29: - - typo fix (thanks to Jane Silber) (lp: #62946) -2006-09-28: - - bugfix in the cdromupgrade script -2006-09-27: - - uploaded a version that only reverts the backport fetching - but no other changes compared to 2006-09-23 -2006-09-27: - - embarrassing bug cdromupgrade.sh -2006-09-26: - - comment out the getRequiredBackport code because we will - not use Breaks for the dapper->edgy upgrade yet - (see #54234 for the rationale) - - updated demotions.cfg for dapper->edgy - - special case the packages affected by the Breaks changes - - make sure that no translations get lost during the upgrade - (thanks to mdz for pointing this out) - - bugfixes -2006-09-23: - - support fetching backports of selected packages first and - use them for the upgrade (needed to support Breaks) - - fetch/use apt/dpkg/python-apt backports for the upgrade -2006-09-06: - - increased the "free-space-savety-buffer" to 100MB -2006-09-05: - - added "RemoveEssentialOk" option and put "sysvinit" into it -2006-09-04: - - set Debug::pkgDepCache::AutoInstall as debug option too - - be more robust against failure from the locales - - remove libgl1-mesa (no longer needed on edgy) -2006-09-03: - - fix in the cdromupgrade script path detection -2006-09-01: - - make the cdromupgrade wrapper work with the compressed version - of the upgrader as put onto the CD - - uploaded -2006-08-30: - - fixes to the cdromupgrade wrapper -2006-08-29: - - always enable the "main" component to make sure it is available - - add download estimated time - - add --cdrom switch to make cdrom based dist-upgrades possible - - better error reporting - - moved the logging into the /var/log/dist-upgrade/ dir - - change the obsoletes calculation when run without network and - consider demotions as obsoletes then (because we can't really - use the "pkg.downloadable" hint without network) - - uploaded -2006-08-18: - - sort the demoted software list -2006-07-31: - - updated to edgy - - uploadedd -2006-05-31: - - fix bug in the free space calculation (#47092) - - updated ReleaseAnnouncement - - updated translations - - fix a missing bindtextdomain - - fix a incorrect ngettext usage - - added quirks handler to fix nvidia-glx issue (#47017) - Thanks to the amazing Kiko for helping improve this! -2006-05-24: - - if the initial "update()" fails, just exit, don't try - to restore the old sources.list (nothing was modified yet) - Ubuntu: #46712 - - fix a bug in the sourcesList rewriting (ubuntu: #46245) - - expand the terminal when no libgnome2-perl is installed - because debconf might want to ask questions (ubuntu: #46214) - - disable the breezy cdrom source to make removal of demoted - packages work properly (ubuntu: #46336) - - translations updated from rosetta - - fixed a bug in the demotions calculation (ubuntu: #46245) - - typos fixed and translations unfuzzied (ubuntu: #46792,#46464) - - upload -2006-05-12: - - space checking improved (ubuntu: #43948) - - show software that was demoted from main -> universe - - improve the remaining time reporting - - translation updates - - upload -2006-05-09: - - upload -2006-05-08: - - fix error when asking for media-change (ubuntu: 43442,43728) -2006-05-02: - - upload -2006-04-28: - - add more sanity checking, if no valid mirror is found in the - sources.list ask for "dumb" rewrite - - if nothing valid was found after a dumb rewrite, add official - sources - - don't report install TIMEOUT over and over in the log - - report what package caused a install TIMEOUT -2006-04-27: - - add a additonal sanity check after the rewriting of the sources.list - (check for BaseMetaPkgs still in the cache) - - on abort reopen() the cache to force writing a new - /var/cache/apt/pkgcache.bin - - use a much more compelte mirror list (based on the information - from https://wiki.ubuntu.com/Archive) -2006-04-25: - - make sure that DistUpgradeView.getTerminal().call() actually - waits until the command has finished (dpkg --configure -a) -2006-04-18: - - add logging to the sources.list modification code - - general logging improvements (thanks to Xavier Poinsard) diff --git a/DistUpgrade/DistInfo.py b/DistUpgrade/DistInfo.py deleted file mode 120000 index bdcd1ba6..00000000 --- a/DistUpgrade/DistInfo.py +++ /dev/null @@ -1 +0,0 @@ -../UpdateManager/Common/DistInfo.py
\ No newline at end of file diff --git a/DistUpgrade/DistUpgrade.cfg b/DistUpgrade/DistUpgrade.cfg deleted file mode 100644 index c39cb9e5..00000000 --- a/DistUpgrade/DistUpgrade.cfg +++ /dev/null @@ -1,53 +0,0 @@ -[View] -View=DistUpgradeViewGtk -#View=DistUpgradeViewNonInteractive -#View=DistUpgradeViewText - -# Distro contains global information about the upgrade -[Distro] -# the meta-pkgs we support -MetaPkgs=ubuntu-desktop, kubuntu-desktop, edubuntu-desktop, xubuntu-desktop -BaseMetaPkgs=ubuntu-minimal, ubuntu-standard -PostUpgradePurge=xorg-common, libgl1-mesa -Demotions=demoted.cfg -RemoveEssentialOk=sysvinit -RemovalBlacklistFile=removal_blacklist.cfg -# if those packages were installed, make sure to keep them installed -# we use this right now to emulate Breaks -KeepInstalledPkgs=gnumeric, gnumeric-gtk, hpijs -KeepInstalledSection=translations - -# information about the individual meta-pkgs -[ubuntu-desktop] -KeyDependencies=gdm, gnome-panel, ubuntu-artwork -# those pkgs will be marked remove right after the distUpgrade in the cache -PostUpgradeRemove=xscreensaver - -[kubuntu-desktop] -KeyDependencies=kdm, kicker, kubuntu-artwork-usplash -# those packages are marked as obsolete right after the upgrade -ForcedObsoletes=ivman - -[edubuntu-desktop] -KeyDependencies=edubuntu-artwork, tuxpaint - -[xubuntu-desktop] -KeyDependencies=xubuntu-artwork-usplash, xubuntu-default-settings, xfce4 - -[Files] -BackupExt=distUpgrade - -[Sources] -From=dapper -To=edgy -ValidOrigin=Ubuntu -ValidMirrors = mirrors.cfg - -[Backports] -Packages=apt,dpkg,python2.4-apt -VersionIdent=~dapper -SourcesList=backport-source.list - - -[Network] -MaxRetries=3 diff --git a/DistUpgrade/DistUpgrade.glade b/DistUpgrade/DistUpgrade.glade deleted file mode 100644 index 2d4ebf92..00000000 --- a/DistUpgrade/DistUpgrade.glade +++ /dev/null @@ -1,2083 +0,0 @@ -<?xml version="1.0" standalone="no"?> <!--*- mode: xml -*--> -<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd"> - -<glade-interface> - -<widget class="GtkWindow" id="window_main"> - <property name="border_width">6</property> - <property name="visible">True</property> - <property name="title">Distribution Upgrade</property> - <property name="type">GTK_WINDOW_TOPLEVEL</property> - <property name="window_position">GTK_WIN_POS_CENTER</property> - <property name="modal">False</property> - <property name="resizable">False</property> - <property name="destroy_with_parent">False</property> - <property name="decorated">True</property> - <property name="skip_taskbar_hint">False</property> - <property name="skip_pager_hint">False</property> - <property name="type_hint">GDK_WINDOW_TYPE_HINT_NORMAL</property> - <property name="gravity">GDK_GRAVITY_NORTH_WEST</property> - <property name="focus_on_map">True</property> - <property name="urgency_hint">True</property> - <signal name="delete_event" handler="on_window_main_delete_event"/> - <signal name="destroy_event" handler="on_window_main_destroy_event"/> - - <child> - <widget class="GtkVBox" id="vbox5"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkVBox" id="vbox1"> - <property name="border_width">6</property> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkLabel" id="label_title"> - <property name="visible">True</property> - <property name="label" translatable="yes"><b><big>Upgrading Ubuntu to version 6.10</big></b></property> - <property name="use_underline">False</property> - <property name="use_markup">True</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox3"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkLabel" id="label17"> - <property name="visible">True</property> - <property name="label" translatable="yes"> </property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkTable" id="table_steps"> - <property name="visible">True</property> - <property name="n_rows">5</property> - <property name="n_columns">2</property> - <property name="homogeneous">False</property> - <property name="row_spacing">6</property> - <property name="column_spacing">6</property> - - <child> - <widget class="GtkLabel" id="label_step1"> - <property name="visible">True</property> - <property name="label" translatable="yes">Preparing the upgrade</property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="left_attach">1</property> - <property name="right_attach">2</property> - <property name="top_attach">0</property> - <property name="bottom_attach">1</property> - <property name="x_options">fill</property> - <property name="y_options"></property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label_step2"> - <property name="visible">True</property> - <property name="label" translatable="yes">Modifying the software channels</property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="left_attach">1</property> - <property name="right_attach">2</property> - <property name="top_attach">1</property> - <property name="bottom_attach">2</property> - <property name="x_options">fill</property> - <property name="y_options"></property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label_step3"> - <property name="visible">True</property> - <property name="label" translatable="yes">Fetching and installing the upgrades</property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="left_attach">1</property> - <property name="right_attach">2</property> - <property name="top_attach">2</property> - <property name="bottom_attach">3</property> - <property name="x_options">fill</property> - <property name="y_options"></property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label_step4"> - <property name="visible">True</property> - <property name="label" translatable="yes">Cleaning up</property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="left_attach">1</property> - <property name="right_attach">2</property> - <property name="top_attach">3</property> - <property name="bottom_attach">4</property> - <property name="x_options">fill</property> - <property name="y_options"></property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label_step5"> - <property name="visible">True</property> - <property name="label" translatable="yes">Restarting the system</property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="left_attach">1</property> - <property name="right_attach">2</property> - <property name="top_attach">4</property> - <property name="bottom_attach">5</property> - <property name="x_options">fill</property> - <property name="y_options"></property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox17"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkArrow" id="arrow_step1"> - <property name="arrow_type">GTK_ARROW_RIGHT</property> - <property name="shadow_type">GTK_SHADOW_OUT</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkImage" id="image_step1"> - <property name="width_request">18</property> - <property name="height_request">18</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="left_attach">0</property> - <property name="right_attach">1</property> - <property name="top_attach">0</property> - <property name="bottom_attach">1</property> - <property name="x_options">fill</property> - <property name="y_options">fill</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox18"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkArrow" id="arrow_step2"> - <property name="arrow_type">GTK_ARROW_RIGHT</property> - <property name="shadow_type">GTK_SHADOW_OUT</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkImage" id="image_step2"> - <property name="width_request">18</property> - <property name="height_request">18</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="left_attach">0</property> - <property name="right_attach">1</property> - <property name="top_attach">1</property> - <property name="bottom_attach">2</property> - <property name="x_options">fill</property> - <property name="y_options">fill</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox19"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkArrow" id="arrow_step3"> - <property name="arrow_type">GTK_ARROW_RIGHT</property> - <property name="shadow_type">GTK_SHADOW_OUT</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkImage" id="image_step3"> - <property name="width_request">18</property> - <property name="height_request">18</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="left_attach">0</property> - <property name="right_attach">1</property> - <property name="top_attach">2</property> - <property name="bottom_attach">3</property> - <property name="x_options">fill</property> - <property name="y_options">fill</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox20"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkArrow" id="arrow_step4"> - <property name="arrow_type">GTK_ARROW_RIGHT</property> - <property name="shadow_type">GTK_SHADOW_OUT</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkImage" id="image_step4"> - <property name="width_request">18</property> - <property name="height_request">18</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="left_attach">0</property> - <property name="right_attach">1</property> - <property name="top_attach">3</property> - <property name="bottom_attach">4</property> - <property name="x_options">fill</property> - <property name="y_options">fill</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox21"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkArrow" id="arrow_step5"> - <property name="arrow_type">GTK_ARROW_RIGHT</property> - <property name="shadow_type">GTK_SHADOW_OUT</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkImage" id="image_step5"> - <property name="width_request">18</property> - <property name="height_request">18</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="left_attach">0</property> - <property name="right_attach">1</property> - <property name="top_attach">4</property> - <property name="bottom_attach">5</property> - <property name="x_options">fill</property> - <property name="y_options">fill</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkVBox" id="vbox5"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">4</property> - - <child> - <widget class="GtkProgressBar" id="progressbar_cache"> - <property name="width_request">350</property> - <property name="visible">True</property> - <property name="orientation">GTK_PROGRESS_LEFT_TO_RIGHT</property> - <property name="fraction">0</property> - <property name="pulse_step">0.10000000149</property> - <property name="text"> </property> - <property name="ellipsize">PANGO_ELLIPSIZE_END</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label_status"> - <property name="visible">True</property> - <property name="label" translatable="yes"></property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">True</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_END</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkExpander" id="expander_terminal"> - <property name="visible">True</property> - <property name="sensitive">False</property> - <property name="can_focus">True</property> - <property name="expanded">False</property> - <property name="spacing">4</property> - - <child> - <widget class="GtkHBox" id="hbox1"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> - - <child> - <widget class="Custom" id="custom_terminal"> - <property name="visible">True</property> - <property name="creation_function">create_terminal</property> - <property name="int1">0</property> - <property name="int2">0</property> - <property name="last_modification_time">Mon, 11 Sep 2006 12:48:22 GMT</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkVScrollbar" id="vscrollbar_terminal"> - <property name="visible">True</property> - <property name="update_policy">GTK_UPDATE_CONTINUOUS</property> - <property name="inverted">False</property> - <property name="adjustment">0 0 0 0 0 0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - </child> - - <child> - <widget class="GtkLabel" id="label6"> - <property name="visible">True</property> - <property name="label" translatable="yes">Terminal</property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="type">label_item</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - </child> -</widget> - -<widget class="GtkDialog" id="dialog_changes"> - <property name="border_width">6</property> - <property name="title" translatable="yes"></property> - <property name="type">GTK_WINDOW_TOPLEVEL</property> - <property name="window_position">GTK_WIN_POS_CENTER_ON_PARENT</property> - <property name="modal">False</property> - <property name="default_width">500</property> - <property name="default_height">400</property> - <property name="resizable">False</property> - <property name="destroy_with_parent">False</property> - <property name="decorated">True</property> - <property name="skip_taskbar_hint">True</property> - <property name="skip_pager_hint">True</property> - <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property> - <property name="gravity">GDK_GRAVITY_NORTH_WEST</property> - <property name="focus_on_map">True</property> - <property name="urgency_hint">True</property> - <property name="has_separator">False</property> - - <child internal-child="vbox"> - <widget class="GtkVBox" id="vbox2"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">6</property> - - <child internal-child="action_area"> - <widget class="GtkHButtonBox" id="hbuttonbox1"> - <property name="visible">True</property> - <property name="layout_style">GTK_BUTTONBOX_END</property> - - <child> - <widget class="GtkButton" id="button_cancel_changes"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="can_focus">True</property> - <property name="label">gtk-cancel</property> - <property name="use_stock">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-6</property> - </widget> - </child> - - <child> - <widget class="GtkButton" id="button_confirm_changes"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="can_focus">True</property> - <property name="label" translatable="yes">_Start Upgrade</property> - <property name="use_underline">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-8</property> - </widget> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="pack_type">GTK_PACK_END</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox12"> - <property name="border_width">6</property> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkImage" id="image9"> - <property name="visible">True</property> - <property name="stock">gtk-dialog-question</property> - <property name="icon_size">6</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkVBox" id="vbox3"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkLabel" id="label_summary"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="label" translatable="yes"></property> - <property name="use_underline">False</property> - <property name="use_markup">True</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">True</property> - <property name="selectable">True</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label_changes"> - <property name="visible">True</property> - <property name="label" translatable="yes"></property> - <property name="use_underline">False</property> - <property name="use_markup">True</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">True</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkExpander" id="expander_details"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="expanded">False</property> - <property name="spacing">6</property> - - <child> - <widget class="GtkScrolledWindow" id="scrolledwindow1"> - <property name="width_request">400</property> - <property name="height_request">200</property> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property> - <property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property> - <property name="shadow_type">GTK_SHADOW_IN</property> - <property name="window_placement">GTK_CORNER_TOP_LEFT</property> - - <child> - <widget class="GtkTreeView" id="treeview_details"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="headers_visible">False</property> - <property name="rules_hint">False</property> - <property name="reorderable">False</property> - <property name="enable_search">True</property> - <property name="fixed_height_mode">False</property> - <property name="hover_selection">False</property> - <property name="hover_expand">False</property> - </widget> - </child> - </widget> - </child> - - <child> - <widget class="GtkLabel" id="label4"> - <property name="visible">True</property> - <property name="label" translatable="yes">Details</property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="type">label_item</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - </child> -</widget> - -<widget class="GtkDialog" id="dialog_restart"> - <property name="border_width">6</property> - <property name="title" translatable="yes"></property> - <property name="type">GTK_WINDOW_TOPLEVEL</property> - <property name="window_position">GTK_WIN_POS_CENTER_ON_PARENT</property> - <property name="modal">False</property> - <property name="resizable">False</property> - <property name="destroy_with_parent">False</property> - <property name="decorated">True</property> - <property name="skip_taskbar_hint">True</property> - <property name="skip_pager_hint">True</property> - <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property> - <property name="gravity">GDK_GRAVITY_NORTH_WEST</property> - <property name="focus_on_map">True</property> - <property name="urgency_hint">True</property> - <property name="has_separator">False</property> - - <child internal-child="vbox"> - <widget class="GtkVBox" id="dialog-vbox1"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child internal-child="action_area"> - <widget class="GtkHButtonBox" id="dialog-action_area1"> - <property name="visible">True</property> - <property name="layout_style">GTK_BUTTONBOX_END</property> - - <child> - <widget class="GtkButton" id="button_restart"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="can_focus">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-8</property> - - <child> - <widget class="GtkAlignment" id="alignment1"> - <property name="visible">True</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xscale">0</property> - <property name="yscale">0</property> - <property name="top_padding">0</property> - <property name="bottom_padding">0</property> - <property name="left_padding">0</property> - <property name="right_padding">0</property> - - <child> - <widget class="GtkHBox" id="hbox6"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">2</property> - - <child> - <widget class="GtkImage" id="image3"> - <property name="visible">True</property> - <property name="stock">gtk-refresh</property> - <property name="icon_size">4</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label20"> - <property name="visible">True</property> - <property name="label" translatable="yes">_Restart Now</property> - <property name="use_underline">True</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - </child> - </widget> - </child> - </widget> - </child> - - <child> - <widget class="GtkButton" id="button_restart"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="can_focus">True</property> - <property name="label">gtk-close</property> - <property name="use_stock">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-7</property> - </widget> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="pack_type">GTK_PACK_END</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox5"> - <property name="border_width">6</property> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkImage" id="image2"> - <property name="visible">True</property> - <property name="stock">gtk-dialog-info</property> - <property name="icon_size">6</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label19"> - <property name="visible">True</property> - <property name="label" translatable="yes"><b><big>Restart the system to complete the upgrade</big></b></property> - <property name="use_underline">False</property> - <property name="use_markup">True</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - </child> -</widget> - -<widget class="GtkDialog" id="dialog_error"> - <property name="border_width">6</property> - <property name="title" translatable="yes"></property> - <property name="type">GTK_WINDOW_TOPLEVEL</property> - <property name="window_position">GTK_WIN_POS_CENTER_ON_PARENT</property> - <property name="modal">False</property> - <property name="resizable">False</property> - <property name="destroy_with_parent">False</property> - <property name="decorated">True</property> - <property name="skip_taskbar_hint">True</property> - <property name="skip_pager_hint">True</property> - <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property> - <property name="gravity">GDK_GRAVITY_NORTH_WEST</property> - <property name="focus_on_map">True</property> - <property name="urgency_hint">True</property> - <property name="has_separator">False</property> - - <child internal-child="vbox"> - <widget class="GtkVBox" id="vbox6"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child internal-child="action_area"> - <widget class="GtkHButtonBox" id="hbuttonbox3"> - <property name="visible">True</property> - <property name="layout_style">GTK_BUTTONBOX_END</property> - - <child> - <widget class="GtkButton" id="button_bugreport"> - <property name="can_default">True</property> - <property name="has_default">True</property> - <property name="can_focus">True</property> - <property name="label" translatable="yes">_Report Bug</property> - <property name="use_underline">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-8</property> - </widget> - </child> - - <child> - <widget class="GtkButton" id="button6"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="has_default">True</property> - <property name="can_focus">True</property> - <property name="label">gtk-close</property> - <property name="use_stock">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-7</property> - </widget> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="pack_type">GTK_PACK_END</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox8"> - <property name="border_width">6</property> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkImage" id="image5"> - <property name="visible">True</property> - <property name="stock">gtk-dialog-error</property> - <property name="icon_size">6</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkVBox" id="vbox7"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkLabel" id="label_error"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="label" translatable="yes"></property> - <property name="use_underline">False</property> - <property name="use_markup">True</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">True</property> - <property name="selectable">True</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkScrolledWindow" id="scroll_error"> - <property name="width_request">400</property> - <property name="height_request">200</property> - <property name="can_focus">True</property> - <property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property> - <property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property> - <property name="shadow_type">GTK_SHADOW_IN</property> - <property name="window_placement">GTK_CORNER_TOP_LEFT</property> - - <child> - <widget class="GtkTextView" id="textview_error"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="editable">False</property> - <property name="overwrite">False</property> - <property name="accepts_tab">True</property> - <property name="justification">GTK_JUSTIFY_LEFT</property> - <property name="wrap_mode">GTK_WRAP_NONE</property> - <property name="cursor_visible">True</property> - <property name="pixels_above_lines">4</property> - <property name="pixels_below_lines">4</property> - <property name="pixels_inside_wrap">0</property> - <property name="left_margin">4</property> - <property name="right_margin">4</property> - <property name="indent">0</property> - <property name="text" translatable="yes"></property> - </widget> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - </child> -</widget> - -<widget class="GtkDialog" id="dialog_obsolete"> - <property name="border_width">6</property> - <property name="title" translatable="yes"></property> - <property name="type">GTK_WINDOW_TOPLEVEL</property> - <property name="window_position">GTK_WIN_POS_CENTER_ON_PARENT</property> - <property name="modal">False</property> - <property name="default_width">500</property> - <property name="default_height">400</property> - <property name="resizable">False</property> - <property name="destroy_with_parent">False</property> - <property name="decorated">True</property> - <property name="skip_taskbar_hint">True</property> - <property name="skip_pager_hint">True</property> - <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property> - <property name="gravity">GDK_GRAVITY_NORTH_WEST</property> - <property name="focus_on_map">True</property> - <property name="urgency_hint">True</property> - <property name="has_separator">False</property> - - <child internal-child="vbox"> - <widget class="GtkVBox" id="vbox8"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">6</property> - - <child internal-child="action_area"> - <widget class="GtkHButtonBox" id="hbuttonbox4"> - <property name="visible">True</property> - <property name="layout_style">GTK_BUTTONBOX_END</property> - - <child> - <widget class="GtkButton" id="button7"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="can_focus">True</property> - <property name="label">gtk-cancel</property> - <property name="use_stock">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-6</property> - </widget> - </child> - - <child> - <widget class="GtkButton" id="button8"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="can_focus">True</property> - <property name="label" translatable="yes">_Continue</property> - <property name="use_underline">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-8</property> - </widget> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="pack_type">GTK_PACK_END</property> - </packing> - </child> - - <child> - <widget class="GtkVBox" id="vbox9"> - <property name="border_width">6</property> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkHBox" id="hbox9"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkImage" id="image6"> - <property name="visible">True</property> - <property name="stock">gtk-dialog-question</property> - <property name="icon_size">6</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkVBox" id="vbox10"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkLabel" id="label26"> - <property name="visible">True</property> - <property name="label" translatable="yes"><b><big>Start the upgrade?</big></b></property> - <property name="use_underline">False</property> - <property name="use_markup">True</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">True</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label27"> - <property name="visible">True</property> - <property name="label"></property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">True</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkExpander" id="expander2"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="expanded">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkScrolledWindow" id="scrolledwindow4"> - <property name="width_request">400</property> - <property name="height_request">200</property> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property> - <property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property> - <property name="shadow_type">GTK_SHADOW_IN</property> - <property name="window_placement">GTK_CORNER_TOP_LEFT</property> - - <child> - <widget class="GtkTreeView" id="treeview2"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="headers_visible">False</property> - <property name="rules_hint">False</property> - <property name="reorderable">False</property> - <property name="enable_search">True</property> - <property name="fixed_height_mode">False</property> - <property name="hover_selection">False</property> - <property name="hover_expand">False</property> - </widget> - </child> - </widget> - </child> - - <child> - <widget class="GtkLabel" id="label25"> - <property name="visible">True</property> - <property name="label" translatable="yes">Details</property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="type">label_item</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - </child> -</widget> - -<widget class="GtkDialog" id="dialog_cancel"> - <property name="border_width">6</property> - <property name="title" translatable="yes"></property> - <property name="type">GTK_WINDOW_TOPLEVEL</property> - <property name="window_position">GTK_WIN_POS_CENTER_ON_PARENT</property> - <property name="modal">False</property> - <property name="resizable">False</property> - <property name="destroy_with_parent">False</property> - <property name="decorated">True</property> - <property name="skip_taskbar_hint">True</property> - <property name="skip_pager_hint">True</property> - <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property> - <property name="gravity">GDK_GRAVITY_NORTH_WEST</property> - <property name="focus_on_map">True</property> - <property name="urgency_hint">True</property> - <property name="has_separator">False</property> - - <child internal-child="vbox"> - <widget class="GtkVBox" id="vbox11"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child internal-child="action_area"> - <widget class="GtkHButtonBox" id="hbuttonbox5"> - <property name="visible">True</property> - <property name="layout_style">GTK_BUTTONBOX_END</property> - - <child> - <widget class="GtkButton" id="button_cancel"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="can_focus">True</property> - <property name="label" translatable="yes">_Cancel Upgrade</property> - <property name="use_underline">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-6</property> - </widget> - </child> - - <child> - <widget class="GtkButton" id="button_resume"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="has_default">True</property> - <property name="can_focus">True</property> - <property name="label" translatable="yes">_Resume Upgrade</property> - <property name="use_underline">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-5</property> - </widget> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="pack_type">GTK_PACK_END</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox11"> - <property name="border_width">6</property> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkImage" id="image8"> - <property name="visible">True</property> - <property name="stock">gtk-dialog-question</property> - <property name="icon_size">6</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label29"> - <property name="visible">True</property> - <property name="label" translatable="yes"><b><big>Cancel the running upgrade?</big></b> - -The system could be in an unusable state if you cancel the upgrade. You are strongly adviced to resume the upgrade.</property> - <property name="use_underline">False</property> - <property name="use_markup">True</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">True</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - </child> -</widget> - -<widget class="GtkDialog" id="dialog_conffile"> - <property name="border_width">5</property> - <property name="title" translatable="yes"></property> - <property name="type">GTK_WINDOW_TOPLEVEL</property> - <property name="window_position">GTK_WIN_POS_CENTER_ON_PARENT</property> - <property name="modal">True</property> - <property name="resizable">False</property> - <property name="destroy_with_parent">False</property> - <property name="decorated">True</property> - <property name="skip_taskbar_hint">False</property> - <property name="skip_pager_hint">False</property> - <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property> - <property name="gravity">GDK_GRAVITY_NORTH_WEST</property> - <property name="focus_on_map">True</property> - <property name="urgency_hint">False</property> - <property name="has_separator">False</property> - - <child internal-child="vbox"> - <widget class="GtkVBox" id="vbox12"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child internal-child="action_area"> - <widget class="GtkHButtonBox" id="hbuttonbox6"> - <property name="visible">True</property> - <property name="layout_style">GTK_BUTTONBOX_END</property> - - <child> - <widget class="GtkButton" id="button9"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="has_default">True</property> - <property name="can_focus">True</property> - <property name="has_focus">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-9</property> - - <child> - <widget class="GtkAlignment" id="alignment2"> - <property name="visible">True</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xscale">0</property> - <property name="yscale">0</property> - <property name="top_padding">0</property> - <property name="bottom_padding">0</property> - <property name="left_padding">0</property> - <property name="right_padding">0</property> - - <child> - <widget class="GtkHBox" id="hbox13"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">2</property> - - <child> - <widget class="GtkImage" id="image10"> - <property name="visible">True</property> - <property name="stock">gtk-cancel</property> - <property name="icon_size">4</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label30"> - <property name="visible">True</property> - <property name="label" translatable="yes">_Keep</property> - <property name="use_underline">True</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - </child> - </widget> - </child> - </widget> - </child> - - <child> - <widget class="GtkButton" id="button10"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="can_focus">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-8</property> - - <child> - <widget class="GtkAlignment" id="alignment3"> - <property name="visible">True</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xscale">0</property> - <property name="yscale">0</property> - <property name="top_padding">0</property> - <property name="bottom_padding">0</property> - <property name="left_padding">0</property> - <property name="right_padding">0</property> - - <child> - <widget class="GtkHBox" id="hbox14"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">2</property> - - <child> - <widget class="GtkImage" id="image11"> - <property name="visible">True</property> - <property name="stock">gtk-ok</property> - <property name="icon_size">4</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label31"> - <property name="visible">True</property> - <property name="label" translatable="yes">_Replace</property> - <property name="use_underline">True</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - </child> - </widget> - </child> - </widget> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="pack_type">GTK_PACK_END</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox15"> - <property name="border_width">6</property> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkImage" id="image12"> - <property name="visible">True</property> - <property name="stock">gtk-dialog-question</property> - <property name="icon_size">6</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkVBox" id="vbox13"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkLabel" id="label_conffile"> - <property name="visible">True</property> - <property name="label" translatable="yes"></property> - <property name="use_underline">False</property> - <property name="use_markup">True</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">True</property> - <property name="selectable">False</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkExpander" id="expander3"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="expanded">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkVBox" id="vbox14"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkScrolledWindow" id="scrolledwindow5"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property> - <property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property> - <property name="shadow_type">GTK_SHADOW_IN</property> - <property name="window_placement">GTK_CORNER_TOP_LEFT</property> - - <child> - <widget class="GtkTextView" id="textview_conffile"> - <property name="height_request">300</property> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="editable">False</property> - <property name="overwrite">False</property> - <property name="accepts_tab">True</property> - <property name="justification">GTK_JUSTIFY_LEFT</property> - <property name="wrap_mode">GTK_WRAP_NONE</property> - <property name="cursor_visible">False</property> - <property name="pixels_above_lines">0</property> - <property name="pixels_below_lines">0</property> - <property name="pixels_inside_wrap">0</property> - <property name="left_margin">0</property> - <property name="right_margin">0</property> - <property name="indent">0</property> - <property name="text" translatable="yes"></property> - </widget> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - </child> - - <child> - <widget class="GtkLabel" id="label33"> - <property name="visible">True</property> - <property name="label" translatable="yes">Difference between the files</property> - <property name="use_underline">False</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="type">label_item</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - </child> -</widget> - -<widget class="GtkDialog" id="dialog_information"> - <property name="border_width">6</property> - <property name="title" translatable="yes"></property> - <property name="type">GTK_WINDOW_TOPLEVEL</property> - <property name="window_position">GTK_WIN_POS_CENTER_ON_PARENT</property> - <property name="modal">False</property> - <property name="resizable">False</property> - <property name="destroy_with_parent">False</property> - <property name="decorated">True</property> - <property name="skip_taskbar_hint">True</property> - <property name="skip_pager_hint">True</property> - <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property> - <property name="gravity">GDK_GRAVITY_NORTH_WEST</property> - <property name="focus_on_map">True</property> - <property name="urgency_hint">True</property> - <property name="has_separator">False</property> - - <child internal-child="vbox"> - <widget class="GtkVBox" id="vbox15"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child internal-child="action_area"> - <widget class="GtkHButtonBox" id="hbuttonbox7"> - <property name="visible">True</property> - <property name="layout_style">GTK_BUTTONBOX_END</property> - - <child> - <widget class="GtkButton" id="button12"> - <property name="visible">True</property> - <property name="can_default">True</property> - <property name="has_default">True</property> - <property name="can_focus">True</property> - <property name="label">gtk-close</property> - <property name="use_stock">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="response_id">-5</property> - </widget> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="pack_type">GTK_PACK_END</property> - </packing> - </child> - - <child> - <widget class="GtkHBox" id="hbox16"> - <property name="border_width">6</property> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkImage" id="image13"> - <property name="visible">True</property> - <property name="stock">gtk-dialog-info</property> - <property name="icon_size">6</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkVBox" id="vbox16"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">12</property> - - <child> - <widget class="GtkLabel" id="label_information"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="label" translatable="yes"></property> - <property name="use_underline">False</property> - <property name="use_markup">True</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">True</property> - <property name="selectable">True</property> - <property name="xalign">0</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">True</property> - </packing> - </child> - - <child> - <widget class="GtkScrolledWindow" id="scroll_information"> - <property name="width_request">400</property> - <property name="height_request">200</property> - <property name="can_focus">True</property> - <property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property> - <property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property> - <property name="shadow_type">GTK_SHADOW_IN</property> - <property name="window_placement">GTK_CORNER_TOP_LEFT</property> - - <child> - <widget class="GtkTextView" id="textview_information"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="editable">False</property> - <property name="overwrite">False</property> - <property name="accepts_tab">True</property> - <property name="justification">GTK_JUSTIFY_LEFT</property> - <property name="wrap_mode">GTK_WRAP_NONE</property> - <property name="cursor_visible">True</property> - <property name="pixels_above_lines">4</property> - <property name="pixels_below_lines">4</property> - <property name="pixels_inside_wrap">0</property> - <property name="left_margin">4</property> - <property name="right_margin">4</property> - <property name="indent">0</property> - <property name="text" translatable="yes"></property> - </widget> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - </child> -</widget> - -</glade-interface> diff --git a/DistUpgrade/DistUpgradeCache.py b/DistUpgrade/DistUpgradeCache.py deleted file mode 100644 index d9dc9959..00000000 --- a/DistUpgrade/DistUpgradeCache.py +++ /dev/null @@ -1,435 +0,0 @@ - -import warnings -warnings.filterwarnings("ignore", "apt API not stable yet", FutureWarning) -import apt -import apt_pkg -import os -import re -import logging -from gettext import gettext as _ -from DistUpgradeConfigParser import DistUpgradeConfig -from DistUpgradeView import FuzzyTimeToStr - -class MyCache(apt.Cache): - # init - def __init__(self, config, progress=None): - apt.Cache.__init__(self, progress) - self.to_install = [] - self.to_remove = [] - - self.config = config - self.metapkgs = self.config.getlist("Distro","MetaPkgs") - - # a list of regexp that are not allowed to be removed - self.removal_blacklist = config.getListFromFile("Distro","RemovalBlacklistFile") - - # properties - @property - def requiredDownload(self): - """ get the size of the packages that are required to download """ - pm = apt_pkg.GetPackageManager(self._depcache) - fetcher = apt_pkg.GetAcquire() - pm.GetArchives(fetcher, self._list, self._records) - return fetcher.FetchNeeded - @property - def additionalRequiredSpace(self): - """ get the size of the additonal required space on the fs """ - return self._depcache.UsrSize - @property - def isBroken(self): - """ is the cache broken """ - return self._depcache.BrokenCount > 0 - - # methods - def downloadable(self, pkg, useCandidate=True): - " check if the given pkg can be downloaded " - if useCandidate: - ver = self._depcache.GetCandidateVer(pkg._pkg) - else: - ver = pkg._pkg.CurrentVer - if ver == None: - return False - return ver.Downloadable - - def fixBroken(self): - """ try to fix broken dependencies on the system, may throw - SystemError when it can't""" - return self._depcache.FixBroken() - - def create_snapshot(self): - """ create a snapshot of the current changes """ - self.to_install = [] - self.to_remove = [] - for pkg in self.getChanges(): - if pkg.markedInstall or pkg.markedUpgrade: - self.to_install.append(pkg.name) - if pkg.markedDelete: - self.to_remove.append(pkg.name) - - def clear(self): - self._depcache.Init() - - def restore_snapshot(self): - """ restore a snapshot """ - self.clear() - for name in self.to_remove: - pkg = self[name] - pkg.markDelete() - for name in self.to_install: - pkg = self[name] - pkg.markInstall() - - def sanityCheck(self, view): - """ check if the cache is ok and if the required metapkgs - are installed - """ - if self.isBroken: - try: - logging.debug("Have broken pkgs, trying to fix them") - self.fixBroken() - except SystemError: - view.error(_("Broken packages"), - _("Your system contains broken packages " - "that couldn't be fixed with this " - "software. " - "Please fix them first using synaptic or " - "apt-get before proceeding.")) - return False - return True - - def markInstall(self, pkg, reason=""): - logging.debug("Installing '%s' (%s)" % (pkg, reason)) - if self.has_key(pkg): - self[pkg].markInstall() - def markRemove(self, pkg, reason=""): - logging.debug("Removing '%s' (%s)" % (pkg, reason)) - if self.has_key(pkg): - self[pkg].markDelete() - def markPurge(self, pkg, reason=""): - logging.debug("Purging '%s' (%s)" % (pkg, reason)) - if self.has_key(pkg): - self._depcache.MarkDelete(self[pkg]._pkg,True) - - def keepInstalledRule(self): - """ run after the dist-upgrade to ensure that certain - packages are kept installed """ - def keepInstalled(self, pkgname, reason): - if (self.has_key(pkgname) - and self[pkgname].isInstalled - and self[pkgname].markedDelete): - self.markInstall(pkgname, reason) - - # first the global list - for pkgname in self.config.getlist("Distro","KeepInstalledPkgs"): - keepInstalled(self, pkgname, "Distro KeepInstalledPkgs rule") - # the the per-metapkg rules - for key in self.metapkgs: - if self.has_key(key) and (self[key].isInstalled or - self[key].markedInstall): - for pkgname in self.config.getlist(key,"KeepInstalledPkgs"): - keepInstalled(self, pkgname, "%s KeepInstalledPkgs rule" % key) - # now the keepInstalledSection code - for section in self.config.getlist("Distro","KeepInstalledSection"): - for pkg in self: - if pkg.markedDelete and pkg.section == section: - keepInstalled(self, pkg.name, "Distro KeepInstalledSection rule: %s" % section) - # the the per-metapkg rules - for key in self.metapkgs: - if self.has_key(key) and (self[key].isInstalled or - self[key].markedInstall): - for section in self.config.getlist(key,"KeepInstalledSection"): - for pkg in self: - if pkg.markedDelete and pkg.section == section: - keepInstalled(self, pkg.name, "%s KeepInstalledSection rule: %s" % (key, section)) - - - def postUpgradeRule(self): - " run after the upgrade was done in the cache " - for (rule, action) in [("Install", self.markInstall), - ("Remove", self.markRemove), - ("Purge", self.markPurge)]: - # first the global list - for pkg in self.config.getlist("Distro","PostUpgrade%s" % rule): - action(pkg, "Distro PostUpgrade%s rule" % rule) - for key in self.metapkgs: - if self.has_key(key) and (self[key].isInstalled or - self[key].markedInstall): - for pkg in self.config.getlist(key,"PostUpgrade%s" % rule): - action(pkg, "%s PostUpgrade%s rule" % (key, rule)) - - # get the distro-specific quirks handler and run it - quirksFuncName = "%sQuirks" % self.config.get("Sources","To") - func = getattr(self, quirksFuncName, None) - if func is not None: - func() - - def edgyQuirks(self): - """ this function works around quirks in the dapper->edgy upgrade """ - logging.debug("running edgyQuirks handler") - for pkg in self: - # deal with the python2.4-$foo -> python-$foo transition - if (pkg.name.startswith("python2.4-") and - pkg.isInstalled and - not pkg.markedUpgrade): - basepkg = "python-"+pkg.name[len("python2.4-"):] - if (self.has_key(basepkg) and not self[basepkg].markedInstall): - try: - self.markInstall(basepkg, - "python2.4->python upgrade rule") - except SystemError, e: - logging.debug("Failed to apply python2.4->python install: %s (%s)" % (basepkg, e)) - # xserver-xorg-input-$foo gives us trouble during the upgrade too - if (pkg.name.startswith("xserver-xorg-input-") and - pkg.isInstalled and - not pkg.markedUpgrade): - try: - self.markInstall(pkg.name, "xserver-xorg-input fixup rule") - except SystemError, e: - logging.debug("Failed to apply fixup: %s (%s)" % (pkg.name, e)) - - # deal with held-backs that are unneeded - for pkgname in ["hpijs", "bzr", "tomboy"]: - if (self.has_key(pkgname) and self[pkgname].isInstalled and - not self[pkgname].markedUpgrade): - try: - self.markInstall(pkgname,"%s quirk upgrade rule" % pkgname) - except SystemError, e: - logging.debug("Failed to apply %s install (%s)" % (pkgname,e)) - # libgl1-mesa-dri from xgl.compiz.info (and friends) breaks the - # upgrade, work around this here by downgrading the package - if self.has_key("libgl1-mesa-dri"): - pkg = self["libgl1-mesa-dri"] - # the version from the compiz repo has a "6.5.1+cvs20060824" ver - if (pkg.candidateVersion == pkg.installedVersion and - "+cvs2006" in pkg.candidateVersion): - for ver in pkg._pkg.VersionList: - # the "officual" edgy version has "6.5.1~20060817-0ubuntu3" - if "~2006" in ver.VerStr: - # ensure that it is from a trusted repo - for (VerFileIter, index) in ver.FileList: - indexfile = self._list.FindIndex(VerFileIter) - if indexfile and indexfile.IsTrusted: - logging.info("Forcing downgrade of libgl1-mesa-dri for xgl.compz.info installs") - self._depcache.SetCandidateVer(pkg._pkg, ver) - break - - # deal with general if $foo is installed, install $bar - for (fr, to) in [("xserver-xorg-driver-all","xserver-xorg-video-all")]: - if self.has_key(fr) and self.has_key(to): - if self[fr].isInstalled and not self[to].markedInstall: - try: - self.markInstall(to,"%s->%s quirk upgrade rule" % (fr, to)) - except SystemError, e: - logging.debug("Failed to apply %s->%s install (%s)" % (fr, to, e)) - - - - def dapperQuirks(self): - """ this function works around quirks in the breezy->dapper upgrade """ - logging.debug("running dapperQuirks handler") - if (self.has_key("nvidia-glx") and self["nvidia-glx"].isInstalled and - self.has_key("nvidia-settings") and self["nvidia-settings"].isInstalled): - logging.debug("nvidia-settings and nvidia-glx is installed") - self.markRemove("nvidia-settings") - self.markInstall("nvidia-glx") - - def distUpgrade(self, view): - try: - # upgrade (and make sure this way that the cache is ok) - self.upgrade(True) - - # see if our KeepInstalled rules are honored - self.keepInstalledRule() - - # and if we have some special rules - self.postUpgradeRule() - - # then see if meta-pkgs are missing - if not self._installMetaPkgs(view): - raise SystemError, _("Can't upgrade required meta-packages") - - # see if it all makes sense - if not self._verifyChanges(): - raise SystemError, _("A essential package would have to be removed") - except SystemError, e: - # FIXME: change the text to something more useful - view.error(_("Could not calculate the upgrade"), - _("A unresolvable problem occurred while " - "calculating the upgrade.\n\n" - "Please report this bug against the 'update-manager' " - "package and include the files in /var/log/dist-upgrade/ " - "in the bugreport.")) - logging.error("Dist-upgrade failed: '%s'", e) - return False - - # check the trust of the packages that are going to change - untrusted = [] - for pkg in self.getChanges(): - if pkg.markedDelete: - continue - # special case because of a bug in pkg.candidateOrigin - if pkg.markedDowngrade: - for ver in pkg._pkg.VersionList: - # version is lower than installed one - if apt_pkg.VersionCompare(ver.VerStr, pkg.installedVersion) < 0: - for (verFileIter,index) in ver.FileList: - if not origin.trusted: - untrusted.append(pkg.name) - continue - origins = pkg.candidateOrigin - trusted = False - for origin in origins: - #print origin - trusted |= origin.trusted - if not trusted: - untrusted.append(pkg.name) - if len(untrusted) > 0: - untrusted.sort() - logging.error("Unauthenticated packages found: '%s'" % \ - " ".join(untrusted)) - # FIXME: maybe ask a question here? instead of failing? - view.error(_("Error authenticating some packages"), - _("It was not possible to authenticate some " - "packages. This may be a transient network problem. " - "You may want to try again later. See below for a " - "list of unauthenticated packages."), - "\n".join(untrusted)) - return False - return True - - def _verifyChanges(self): - """ this function tests if the current changes don't violate - our constrains (blacklisted removals etc) - """ - removeEssentialOk = self.config.getlist("Distro","RemoveEssentialOk") - for pkg in self.getChanges(): - if pkg.markedDelete and self._inRemovalBlacklist(pkg.name): - logging.debug("The package '%s' is marked for removal but it's in the removal blacklist", pkg.name) - return False - if pkg.markedDelete and (pkg._pkg.Essential == True and - not pkg.name in removeEssentialOk): - logging.debug("The package '%s' is marked for removal but it's a ESSENTIAL package", pkg.name) - return False - return True - - def _installMetaPkgs(self, view): - # helper for this func - def metaPkgInstalled(): - metapkg_found = False - for key in metapkgs: - if self.has_key(key): - pkg = self[key] - if (pkg.isInstalled and not pkg.markedDelete) \ - or self[key].markedInstall: - metapkg_found=True - return metapkg_found - - # now check for ubuntu-desktop, kubuntu-desktop, edubuntu-desktop - metapkgs = self.config.getlist("Distro","MetaPkgs") - - # we never go without ubuntu-base - for pkg in self.config.getlist("Distro","BaseMetaPkgs"): - self[pkg].markInstall() - - # every meta-pkg that is installed currently, will be marked - # install (that result in a upgrade and removes a markDelete) - for key in metapkgs: - try: - if self.has_key(key) and self[key].isInstalled: - logging.debug("Marking '%s' for upgrade" % key) - self[key].markUpgrade() - except SystemError, e: - logging.debug("Can't mark '%s' for upgrade (%s)" % (key,e)) - return False - # check if we have a meta-pkg, if not, try to guess which one to pick - if not metaPkgInstalled(): - logging.debug("no {ubuntu,edubuntu,kubuntu}-desktop pkg installed") - for key in metapkgs: - deps_found = True - for pkg in self.config.getlist(key,"KeyDependencies"): - deps_found &= self.has_key(pkg) and self[pkg].isInstalled - if deps_found: - logging.debug("guessing '%s' as missing meta-pkg" % key) - try: - self[key].markInstall() - except SystemError, e: - logging.error("failed to mark '%s' for install (%s)" % (key,e)) - view.error(_("Can't install '%s'" % key), - _("It was impossible to install a " - "required package. Please report " - "this as a bug. ")) - return False - # check if we actually found one - if not metaPkgInstalled(): - # FIXME: provide a list - view.error(_("Can't guess meta-package"), - _("Your system does not contain a " - "ubuntu-desktop, kubuntu-desktop or " - "edubuntu-desktop package and it was not " - "possible to detect which version of " - "ubuntu you are running.\n " - "Please install one of the packages " - "above first using synaptic or " - "apt-get before proceeding.")) - return False - return True - - def _inRemovalBlacklist(self, pkgname): - for expr in self.removal_blacklist: - if re.compile(expr).match(pkgname): - return True - return False - - def _tryMarkObsoleteForRemoval(self, pkgname, remove_candidates, foreign_pkgs): - # this is a delete candidate, only actually delete, - # if it dosn't remove other packages depending on it - # that are not obsolete as well - self.create_snapshot() - try: - self[pkgname].markDelete() - for pkg in self.getChanges(): - if pkg.name not in remove_candidates or \ - pkg.name in foreign_pkgs or \ - self._inRemovalBlacklist(pkg.name): - self.restore_snapshot() - return False - except (SystemError,KeyError),e: - logging.warning("_tryMarkObsoleteForRemoval failed for '%s' (%s)" % (pkgname,e)) - self.restore_snapshot() - return False - return True - - def _getObsoletesPkgs(self): - " get all package names that are not downloadable " - obsolete_pkgs =set() - for pkg in self: - if pkg.isInstalled: - if not self.downloadable(pkg): - obsolete_pkgs.add(pkg.name) - return obsolete_pkgs - - def _getForeignPkgs(self, allowed_origin, fromDist, toDist): - """ get all packages that are installed from a foreign repo - (and are actually downloadable) - """ - foreign_pkgs=set() - for pkg in self: - if pkg.isInstalled and self.downloadable(pkg): - # assume it is foreign and see if it is from the - # official archive - foreign=True - for origin in pkg.candidateOrigin: - if fromDist in origin.archive and \ - origin.origin == allowed_origin: - foreign = False - if toDist in origin.archive and \ - origin.origin == allowed_origin: - foreign = False - if foreign: - foreign_pkgs.add(pkg.name) - return foreign_pkgs - -if __name__ == "__main__": - import DistUpgradeConfigParser - c = MyCache(DistUpgradeConfigParser.DistUpgradeConfig(".")) - c.clear() diff --git a/DistUpgrade/DistUpgradeConfigParser.py b/DistUpgrade/DistUpgradeConfigParser.py deleted file mode 100644 index d5391939..00000000 --- a/DistUpgrade/DistUpgradeConfigParser.py +++ /dev/null @@ -1,29 +0,0 @@ -from ConfigParser import ConfigParser, NoOptionError - - -class DistUpgradeConfig(ConfigParser): - def __init__(self, datadir, name="DistUpgrade.cfg"): - ConfigParser.__init__(self) - self.datadir=datadir - self.read([datadir+"/"+name]) - def getlist(self, section, option): - try: - tmp = self.get(section, option) - except NoOptionError: - return [] - items = [x.strip() for x in tmp.split(",")] - return items - def getListFromFile(self, section, option): - try: - filename = self.get(section, option) - except NoOptionError: - return [] - items = [x.strip() for x in open(self.datadir+"/"+filename)] - return filter(lambda s: not s.startswith("#") and not s == "", items) - - -if __name__ == "__main__": - c = DistUpgradeConfig() - print c.getlist("Distro","MetaPkgs") - print c.getlist("Distro","ForcedPurges") - print c.getListFromFile("Sources","ValidMirrors") diff --git a/DistUpgrade/DistUpgradeControler.py b/DistUpgrade/DistUpgradeControler.py deleted file mode 100644 index 4e76a65d..00000000 --- a/DistUpgrade/DistUpgradeControler.py +++ /dev/null @@ -1,767 +0,0 @@ -# DistUpgradeControler.py -# -# Copyright (c) 2004-2006 Canonical -# -# Author: Michael Vogt <michael.vogt@ubuntu.com> -# -# This program is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -# USA - - -import warnings -warnings.filterwarnings("ignore", "apt API not stable yet", FutureWarning) -import apt -import apt_pkg -import sys -import os -import subprocess -import logging -import re -import statvfs -import shutil -import glob -from DistUpgradeConfigParser import DistUpgradeConfig - -from aptsources import SourcesList, SourceEntry, Distribution, is_mirror -from gettext import gettext as _ -import gettext -from DistUpgradeCache import MyCache - -class AptCdrom(object): - def __init__(self, view, path): - self.view = view - self.cdrompath = path - - def restoreBackup(self, backup_ext): - " restore the backup copy of the cdroms.list file (*not* sources.list)! " - cdromstate = os.path.join(apt_pkg.Config.FindDir("Dir::State"), - apt_pkg.Config.Find("Dir::State::cdroms")) - if os.path.exists(cdromstate+backup_ext): - shutil.copy(cdromstate+backup_ext, cdromstate) - # mvo: we don't have to care about restoring the sources.list here because - # aptsources will do this for us anyway - - def add(self, backup_ext=None): - " add a cdrom to apts database " - logging.debug("AptCdrom.add() called with '%s'", self.cdrompath) - # do backup (if needed) of the cdroms.list file - if backup_ext: - cdromstate = os.path.join(apt_pkg.Config.FindDir("Dir::State"), - apt_pkg.Config.Find("Dir::State::cdroms")) - if os.path.exists(cdromstate): - shutil.copy(cdromstate, cdromstate+backup_ext) - # do the actual work - apt_pkg.Config.Set("Acquire::cdrom::mount",self.cdrompath) - apt_pkg.Config.Set("APT::CDROM::NoMount","true") - cdrom = apt_pkg.GetCdrom() - # FIXME: add cdrom progress here for the view - progress = self.view.getCdromProgress() - try: - res = cdrom.Add(progress) - except SystemError, e: - logging.error("can't add cdrom: %s" % e) - self.view.error(_("Failed to add the CD"), - _("There was a error adding the CD, the " - "upgrade will abort. Please report this as " - "a bug if this is a valid Ubuntu CD.\n\n" - "The error message was:\n'%s'") % e) - return False - logging.debug("AptCdrom.add() returned: %s" % res) - return res - - def __nonzero__(self): - """ helper to use this as 'if cdrom:' """ - return self.cdrompath is not None - -class DistUpgradeControler(object): - """ this is the controler that does most of the work """ - - def __init__(self, distUpgradeView, options=None, datadir=None): - # setup the pathes - localedir = "/usr/share/locale/update-manager/" - if datadir == None: - datadir = os.getcwd() - localedir = os.path.join(datadir,"mo") - gladedir = datadir - self.datadir = datadir - - self.options = options - - # init gettext - gettext.bindtextdomain("update-manager",localedir) - gettext.textdomain("update-manager") - - # setup the view - self._view = distUpgradeView - self._view.updateStatus(_("Reading cache")) - self.cache = None - - if not self.options or self.options.withNetwork == None: - self.useNetwork = True - else: - self.useNetwork = self.options.withNetwork - if options: - cdrompath = options.cdromPath - else: - cdrompath = None - self.aptcdrom = AptCdrom(distUpgradeView, cdrompath) - - # the configuration - self.config = DistUpgradeConfig(datadir) - self.sources_backup_ext = "."+self.config.get("Files","BackupExt") - - # some constants here - self.fromDist = self.config.get("Sources","From") - self.toDist = self.config.get("Sources","To") - self.origin = self.config.get("Sources","ValidOrigin") - - # forced obsoletes - self.forced_obsoletes = self.config.getlist("Distro","ForcedObsoletes") - - # turn on debuging in the cache - apt_pkg.Config.Set("Debug::pkgProblemResolver","true") - apt_pkg.Config.Set("Debug::pkgDepCache::AutoInstall","true") - fd = os.open("/var/log/dist-upgrade/apt.log", - os.O_RDWR|os.O_CREAT|os.O_APPEND, 0644) - os.dup2(fd,1) - os.dup2(fd,2) - - def openCache(self): - self.cache = MyCache(self.config, self._view.getOpCacheProgress()) - - def prepare(self): - """ initial cache opening, sanity checking, network checking """ - try: - self.openCache() - except SystemError, e: - logging.error("openCache() failed: '%s'" % e) - return False - if not self.cache.sanityCheck(self._view): - return False - # FIXME: we may try to find out a bit more about the network - # connection here and ask more inteligent questions - if self.aptcdrom and self.options and self.options.withNetwork == None: - res = self._view.askYesNoQuestion(_("Fetch data from the network for the upgrade?"), - _("The upgrade can use the network to check " - "the latest updates and to fetch packages that are not on the " - "current CD.\n" - "If you have fast or inexpensive network access you should answer " - "'Yes' here. If networking is expensive for you choose 'No'.") - ) - self.useNetwork = res - logging.debug("useNetwork: '%s' (selected by user)" % res) - return True - - def rewriteSourcesList(self, mirror_check=True): - logging.debug("rewriteSourcesList()") - - # enable main (we always need this!) - distro = Distribution() - distro.get_sources(self.sources) - # make sure that main is enabled - distro.enable_component(self.sources, "main") - - # this must map, i.e. second in "from" must be the second in "to" - # (but they can be different, so in theory we could exchange - # component names here) - fromDists = [self.fromDist, - self.fromDist+"-security", - self.fromDist+"-updates", - self.fromDist+"-backports" - ] - toDists = [self.toDist, - self.toDist+"-security", - self.toDist+"-updates", - self.toDist+"-backports" - ] - - # list of valid mirrors that we can add - valid_mirrors = self.config.getListFromFile("Sources","ValidMirrors") - - self.sources_disabled = False - - # look over the stuff we have - foundToDist = False - for entry in self.sources: - - # ignore invalid records or disabled ones - if entry.invalid or entry.disabled: - continue - - # we disable breezy cdrom sources to make sure that demoted - # packages are removed - if entry.uri.startswith("cdrom:") and entry.dist == self.fromDist: - entry.disabled = True - continue - # ignore cdrom sources otherwise - elif entry.uri.startswith("cdrom:"): - continue - - logging.debug("examining: '%s'" % entry) - # check if it's a mirror (or offical site) - validMirror = False - for mirror in valid_mirrors: - if not mirror_check or is_mirror(mirror,entry.uri): - validMirror = True - # security is a special case - res = not entry.uri.startswith("http://security.ubuntu.com") and not entry.disabled - if entry.dist in toDists: - # so the self.sources.list is already set to the new - # distro - logging.debug("entry '%s' is already set to new dist" % entry) - foundToDist |= res - elif entry.dist in fromDists: - foundToDist |= res - entry.dist = toDists[fromDists.index(entry.dist)] - logging.debug("entry '%s' updated to new dist" % entry) - else: - # disable all entries that are official but don't - # point to either "to" or "from" dist - entry.disabled = True - self.sources_disabled = True - logging.debug("entry '%s' was disabled (unknown dist)" % entry) - # it can only be one valid mirror, so we can break here - break - # disable anything that is not from a official mirror - if not validMirror: - entry.disabled = True - self.sources_disabled = True - logging.debug("entry '%s' was disabled (unknown mirror)" % entry) - return foundToDist - - def updateSourcesList(self): - logging.debug("updateSourcesList()") - self.sources = SourcesList(matcherPath=".") - if not self.rewriteSourcesList(mirror_check=True): - logging.error("No valid mirror found") - res = self._view.askYesNoQuestion(_("No valid mirror found"), - _("While scaning your repository " - "information no mirror entry for " - "the upgrade was found." - "This cam happen if you run a internal " - "mirror or if the mirror information is " - "out of date.\n\n" - "Do you want to rewrite your " - "'sources.list' file anyway? If you choose " - "'Yes' here it will update all '%s' to '%s' " - "entries.\n" - "If you select 'no' the update will cancel." - ) % (self.fromDist, self.toDist)) - if res: - # re-init the sources and try again - self.sources = SourcesList(matcherPath=".") - if not self.rewriteSourcesList(mirror_check=False): - #hm, still nothing useful ... - prim = _("Generate default sources?") - secon = _("After scanning your 'sources.list' no " - "valid entry for '%s' was found.\n\n" - "Should default entries for '%s' be " - "added? If you select 'No' the update " - "will cancel.") % (self.fromDist, self.toDist) - if not self._view.askYesNoQuestion(prim, secon): - self.abort() - - # add some defaults here - # FIXME: find mirror here - uri = "http://archive.ubuntu.com/ubuntu" - comps = ["main","restricted"] - self.sources.add("deb", uri, self.toDist, comps) - self.sources.add("deb", uri, self.toDist+"-updates", comps) - self.sources.add("deb", - "http://security.ubuntu.com/ubuntu/", - self.toDist+"-security", comps) - else: - self.abort() - - # write (well, backup first ;) ! - self.sources.backup(self.sources_backup_ext) - self.sources.save() - - # re-check if the written self.sources are valid, if not revert and - # bail out - # TODO: check if some main packages are still available or if we - # accidently shot them, if not, maybe offer to write a standard - # sources.list? - try: - sourceslist = apt_pkg.GetPkgSourceList() - sourceslist.ReadMainList() - except SystemError: - logging.error("Repository information invalid after updating (we broke it!)") - self._view.error(_("Repository information invalid"), - _("Upgrading the repository information " - "resulted in a invalid file. Please " - "report this as a bug.")) - return False - - if self.sources_disabled: - self._view.information(_("Third party sources disabled"), - _("Some third party entries in your sources.list " - "were disabled. You can re-enable them " - "after the upgrade with the " - "'software-properties' tool or with synaptic." - )) - return True - - def _logChanges(self): - # debuging output - logging.debug("About to apply the following changes") - inst = [] - up = [] - rm = [] - held = [] - for pkg in self.cache: - if pkg.markedInstall: inst.append(pkg.name) - elif pkg.markedUpgrade: up.append(pkg.name) - elif pkg.markedDelete: rm.append(pkg.name) - elif (pkg.isInstalled and pkg.isUpgradable): held.append(pkg.name) - logging.debug("Held-back: %s" % " ".join(held)) - logging.debug("Remove: %s" % " ".join(rm)) - logging.debug("Install: %s" % " ".join(inst)) - logging.debug("Upgrade: %s" % " ".join(up)) - - - def doPreUpgrade(self): - # FIXME: check out what packages are downloadable etc to - # compare the list after the update again - self.obsolete_pkgs = self.cache._getObsoletesPkgs() - self.foreign_pkgs = self.cache._getForeignPkgs(self.origin, self.fromDist, self.toDist) - logging.debug("Foreign: %s" % " ".join(self.foreign_pkgs)) - logging.debug("Obsolete: %s" % " ".join(self.obsolete_pkgs)) - - def doUpdate(self): - if not self.useNetwork: - logging.debug("doUpdate() will not use the network because self.useNetwork==false") - return True - self.cache._list.ReadMainList() - progress = self._view.getFetchProgress() - # FIXME: retry here too? just like the DoDistUpgrade? - # also remove all files from the lists partial dir! - currentRetry = 0 - maxRetries = int(self.config.get("Network","MaxRetries")) - while currentRetry < maxRetries: - try: - res = self.cache.update(progress) - except IOError, e: - logging.error("IOError in cache.update(): '%s'. Retrying (currentRetry: %s)" % (e,currentRetry)) - currentRetry += 1 - continue - # no exception, so all was fine, we are done - return True - - logging.error("doUpdate() failed complettely") - self._view.error(_("Error during update"), - _("A problem occured during the update. " - "This is usually some sort of network " - "problem, please check your network " - "connection and retry."), "%s" % e) - return False - - - def _checkFreeSpace(self): - " this checks if we have enough free space on /var and /usr" - err_sum = _("Not enough free disk space") - err_long= _("The upgrade aborts now. " - "Please free at least %s of disk space on %s. " - "Empty your trash and remove temporary " - "packages of former installations using " - "'sudo apt-get clean'.") - - # gather/log some staticts - mnt_map = {} - for d in ["/","/usr","/var","/boot"]: - st = os.statvfs(d) - free = st[statvfs.F_BAVAIL]*st[statvfs.F_FRSIZE] - if st in mnt_map: - logging.debug("Dir %s mounted on %s" % (d,mnt_map[st])) - else: - logging.debug("Free space on %s: %s" % (d,free)) - mnt_map[st] = d - del mnt_map - - # first check for /var (or where the archives are downloaded too) - archivedir = apt_pkg.Config.FindDir("Dir::Cache::archives") - st_archivedir = os.statvfs(archivedir) - free = st_archivedir[statvfs.F_BAVAIL]*st_archivedir[statvfs.F_FRSIZE] - logging.debug("required download: %s " % self.cache.requiredDownload) - logging.debug("free on %s: %s " % (archivedir, free)) - if self.cache.requiredDownload > free: - free_at_least = apt_pkg.SizeToStr(self.cache.requiredDownload-free) - logging.error("not enough free space (missing %s)" % free_at_least) - self._view.error(err_sum, err_long % (free_at_least,archivedir)) - return False - - # then check for /usr assuming that all the data goes into /usr - # this won't catch space problems when e.g. /boot,/usr/,/ are all - # seperated partitions, but with a fragmented - # patition layout we can't do a lot better because we don't know - # the space-requirements on a per dir basis inside the deb without - # looking into each - logging.debug("need additional space: %s" % self.cache.additionalRequiredSpace) - dir = "/usr" - st_usr = os.statvfs(dir) - if st_archivedir == st_usr: - # we are on the same filesystem, so we need to take the space - # for downloading the debs into account - free -= self.cache.requiredDownload - logging.debug("/usr on same fs as %s, taking dl-size into account, new free: %s" % (archivedir, free)) - else: - free = st_usr[statvfs.F_BAVAIL]*st_usr[statvfs.F_FRSIZE] - logging.debug("/usr on different fs than %s, free: %s" % (archivedir, free)) - - safety_buffer = 1024*1024*100 # 100 Mb - logging.debug("using safety buffer: %s" % safety_buffer) - if (self.cache.additionalRequiredSpace+safety_buffer) > free: - free_at_least = apt_pkg.SizeToStr(self.cache.additionalRequiredSpace+safety_buffer-free) - logging.error("not enough free space, we need addional %s" % free_at_least) - self._view.error(err_sum, err_long % (free_at_least,dir)) - return False - - # FIXME: we should try to esitmate if "/" has enough free space, - # linux-restricted-modules and linux-image- are both putting there - # modules there and those take a lot of space - - return True - - def askDistUpgrade(self): - if not self.cache.distUpgrade(self._view): - return False - changes = self.cache.getChanges() - # log the changes for debuging - self._logChanges() - # check if we have enough free space - if not self._checkFreeSpace(): - return False - # ask the user if he wants to do the changes - res = self._view.confirmChanges(_("Do you want to start the upgrade?"), - changes, - self.cache.requiredDownload) - return res - - def doDistUpgrade(self): - if self.options and self.options.haveBackports: - backportsdir = os.getcwd()+"/backports" - apt_pkg.Config.Set("Dir::Bin::dpkg",backportsdir+"/usr/bin/dpkg"); - currentRetry = 0 - fprogress = self._view.getFetchProgress() - iprogress = self._view.getInstallProgress(self.cache) - # retry the fetching in case of errors - maxRetries = int(self.config.get("Network","MaxRetries")) - while currentRetry < maxRetries: - try: - res = self.cache.commit(fprogress,iprogress) - except SystemError, e: - # installing the packages failed, can't be retried - logging.error("SystemError from cache.commit(): %s" % e) - self._view.getTerminal().call(["dpkg","--configure","-a"]) - self._view.error(_("Could not install the upgrades"), - _("The upgrade aborts now. Your system " - "could be in an unusable state. A recovery " - "was run (dpkg --configure -a).\n\n" - "Please report this bug against the 'update-manager' " - "package and include the files in /var/log/dist-upgrade/ " - "in the bugreport."), - "%s" % e) - return False - except IOError, e: - # fetch failed, will be retried - logging.error("IOError in cache.commit(): '%s'. Retrying (currentTry: %s)" % (e,currentRetry)) - currentRetry += 1 - continue - # no exception, so all was fine, we are done - return True - - # maximum fetch-retries reached without a successful commit - logging.error("giving up on fetching after maximum retries") - self._view.error(_("Could not download the upgrades"), - _("The upgrade aborts now. Please check your "\ - "internet connection or "\ - "installation media and try again. "), - "%s" % e) - # abort here because we want our sources.list back - self.abort() - - - - def doPostUpgrade(self): - self.openCache() - # check out what packages are cruft now - # use self.{foreign,obsolete}_pkgs here and see what changed - now_obsolete = self.cache._getObsoletesPkgs() - now_foreign = self.cache._getForeignPkgs(self.origin, self.fromDist, self.toDist) - logging.debug("Obsolete: %s" % " ".join(now_obsolete)) - logging.debug("Foreign: %s" % " ".join(now_foreign)) - - # now get the meta-pkg specific obsoletes and purges - for pkg in self.config.getlist("Distro","MetaPkgs"): - if self.cache.has_key(pkg) and self.cache[pkg].isInstalled: - self.forced_obsoletes.extend(self.config.getlist(pkg,"ForcedObsoletes")) - logging.debug("forced_obsoletes: %s", self.forced_obsoletes) - - # check what packages got demoted - demotions_file = self.config.get("Distro","Demotions") - demotions = set() - if os.path.exists(demotions_file): - map(lambda pkgname: demotions.add(pkgname.strip()), - filter(lambda line: not line.startswith("#"), - open(demotions_file).readlines())) - installed_demotions = filter(lambda pkg: pkg.isInstalled and pkg.name in demotions, self.cache) - if len(installed_demotions) > 0: - demoted = [pkg.name for pkg in installed_demotions] - demoted.sort() - logging.debug("demoted: '%s'" % " ".join(demoted)) - self._view.information(_("Support for some applications ended"), - _("Canonical Ltd. no longer provides " - "support for the following software " - "packages. You can still get support " - "from the community.\n\n" - "If you have not enabled community " - "maintained software (universe), " - "these packages will be suggested for " - "removal in the next step."), - "\n".join(demoted)) - - # mark packages that are now obsolete (and where not obsolete - # before) to be deleted. make sure to not delete any foreign - # (that is, not from ubuntu) packages - if self.useNetwork: - # we can only do the obsoletes calculation here if we use a - # network. otherwise after rewriting the sources.list everything - # that is not on the CD becomes obsolete (not-downloadable) - remove_candidates = now_obsolete - self.obsolete_pkgs - else: - # initial remove candidates when no network is used should - # be the demotions to make sure we don't leave potential - # unsupported software - remove_candidates = set(installed_demotions) - remove_candidates |= set(self.forced_obsoletes) - logging.debug("remove_candidates: '%s'" % remove_candidates) - logging.debug("Start checking for obsolete pkgs") - for pkgname in remove_candidates: - if pkgname not in self.foreign_pkgs: - if not self.cache._tryMarkObsoleteForRemoval(pkgname, remove_candidates, self.foreign_pkgs): - logging.debug("'%s' scheduled for remove but not in remove_candiates, skipping", pkgname) - logging.debug("Finish checking for obsolete pkgs") - - # get changes - changes = self.cache.getChanges() - logging.debug("The following packages are remove candidates: %s" % " ".join([pkg.name for pkg in changes])) - summary = _("Remove obsolete packages?") - actions = [_("_Skip This Step"), _("_Remove")] - # FIXME Add an explanation about what obsolete pacages are - #explanation = _("") - if len(changes) > 0 and \ - self._view.confirmChanges(summary, changes, 0, actions): - fprogress = self._view.getFetchProgress() - iprogress = self._view.getInstallProgress(self.cache) - try: - res = self.cache.commit(fprogress,iprogress) - except (SystemError, IOError), e: - logging.error("cache.commit() in doPostUpgrade() failed: %s" % e) - self._view.error(_("Error during commit"), - _("Some problem occured during the clean-up. " - "Please see the below message for more " - "information. "), - "%s" % e) - - def abort(self): - """ abort the upgrade, cleanup (as much as possible) """ - if hasattr(self, "sources"): - self.sources.restoreBackup(self.sources_backup_ext) - if hasattr(self, "aptcdrom"): - self.aptcdrom.restoreBackup(self.sources_backup_ext) - # generate a new cache - self._view.updateStatus(_("Restoring original system state")) - self._view.abort() - self.openCache() - sys.exit(1) - - def getRequiredBackports(self): - " download the backports specified in DistUpgrade.cfg " - # add the backports sources.list fragment - shutil.copy(self.config.get("Backports","SourcesList"), - apt_pkg.Config.FindDir("Dir::Etc::sourceparts")) - # run update - self.doUpdate() - self.openCache() - - # save cachedir and setup new one - cachedir = apt_pkg.Config.Find("Dir::Cache::archives") - cwd = os.getcwd() - backportsdir = os.path.join(os.getcwd(),"backports") - if not os.path.exists(backportsdir): - os.mkdir(backportsdir) - if not os.path.exists(os.path.join(backportsdir,"partial")): - os.mkdir(os.path.join(backportsdir,"partial")) - os.chdir(backportsdir) - apt_pkg.Config.Set("Dir::Cache::archives",backportsdir) - - # mark the backports for upgrade and get them - fetcher = apt_pkg.GetAcquire(self._view.getFetchProgress()) - # FIXME: add a version line to the cfg file to make sure - # we get the right version file! and add sanity checking - # that we don't get (accidently) the edgy version - for pkgname in self.config.getlist("Backports","Packages"): - pkg = self.cache[pkgname] - # look for the right version (backport) - for ver in pkg._pkg.VersionList: - print ver.VerStr - if self.config.get("Backports","VersionIdent") in ver.VerStr: - break - else: - # FIXME: be more clever here (exception) - raise Exception, "No backport found!?!" - return False - if ver.FileList == None: - print "No FileList for: %s " % self._pkg.Name() - return False - f, index = ver.FileList.pop(0) - pkg._records.Lookup((f,index)) - path = apt_pkg.ParseSection(pkg._records.Record)["Filename"] - for (packagefile,i) in ver.FileList: - indexfile = self.cache._list.FindIndex(packagefile) - if indexfile: - match = re.match(r"<.*ArchiveURI='(.*)'>$", - str(indexfile)) - if match: - uri = match.group(1) + path - apt_pkg.GetPkgAcqFile(fetcher, uri=uri, - size=ver.Size, - descr=_("Fetching backport of '%s'") % pkgname) - res = fetcher.Run() - if res != fetcher.ResultContinue: - # ick! error ... - return False - - # reset the cache dir - os.unlink(apt_pkg.Config.FindDir("Dir::Etc::sourceparts")+"/backport-source.list") - apt_pkg.Config.Set("Dir::Cache::archives",cachedir) - os.chdir(cwd) - # unpack it - for deb in glob.glob(backportsdir+"/*.deb"): - ret = os.system("dpkg-deb -x %s %s" % (deb, backportsdir)) - # FIXME: do error checking - return self.setupRequiredBackports(backportsdir) - - def setupRequiredBackports(self, backportsdir): - " setup the required backports in a evil way " - # setup some pathes to make sure the new stuff is used - os.environ["LD_LIBRARY_PATH"] = backportsdir+"/usr/lib" - os.environ["PYTHONPATH"] = backportsdir+"/usr/lib/python2.4/site-packages/" - os.environ["PATH"] = "%s:%s" % (backportsdir+"/usr/bin", - os.getenv("PATH")) - - # now exec self again - args = sys.argv+["--have-backports"] - if self.useNetwork: - args.append("--with-network") - else: - args.append("--without-network") - os.execve(sys.argv[0],args, os.environ) - - # this is the core - def edgyUpgrade(self): - # sanity check (check for ubuntu-desktop, brokenCache etc) - self._view.updateStatus(_("Checking package manager")) - self._view.setStep(1) - - if not self.prepare(): - logging.error("self.prepared() failed") - self._view.error(_("Preparing the upgrade failed"), - _("Preparing the system for the upgrade " - "failed. Please report this as a bug " - "against the 'update-manager' " - "package and include the files in " - "/var/log/dist-upgrade/ " - "in the bugreport." )) - sys.exit(1) - - # mvo: commented out for now, see #54234, this needs to be - # refactored to use a arch=any tarball - #if self.options and self.options.haveBackports == False: - # # get backported packages (if needed) - # self.getRequiredBackports() - - # run a "apt-get update" now - if not self.doUpdate(): - sys.exit(1) - - # do pre-upgrade stuff (calc list of obsolete pkgs etc) - self.doPreUpgrade() - - # update sources.list - self._view.setStep(2) - self._view.updateStatus(_("Updating repository information")) - if not self.updateSourcesList(): - self.abort() - - # add cdrom (if we have one) - if (self.aptcdrom and - not self.aptcdrom.add(self.sources_backup_ext)): - sys.exit(1) - - # then update the package index files - if not self.doUpdate(): - self.abort() - - # then open the cache (again) - self._view.updateStatus(_("Checking package manager")) - self.openCache() - # now check if we still have some key packages after the update - # if not something went seriously wrong - for pkg in self.config.getlist("Distro","BaseMetaPkgs"): - if not self.cache.has_key(pkg): - # FIXME: we could offer to add default source entries here, - # but we need to be careful to not duplicate them - # (i.e. the error here could be something else than - # missing sources entires but network errors etc) - logging.error("No '%s' after sources.list rewrite+update") - self._view.error(_("Invalid package information"), - _("After your package information was " - "updated the essential package '%s' can " - "not be found anymore.\n" - "This indicates a serious error, please " - "report this bug against the 'update-manager' " - "package and include the files in /var/log/dist-upgrade/ " - "in the bugreport.") % pkg) - self.abort() - - # calc the dist-upgrade and see if the removals are ok/expected - # do the dist-upgrade - self._view.setStep(3) - self._view.updateStatus(_("Asking for confirmation")) - if not self.askDistUpgrade(): - self.abort() - - self._view.updateStatus(_("Upgrading")) - if not self.doDistUpgrade(): - # don't abort here, because it would restore the sources.list - sys.exit(1) - - # do post-upgrade stuff - self._view.setStep(4) - self._view.updateStatus(_("Searching for obsolete software")) - self.doPostUpgrade() - - # done, ask for reboot - self._view.setStep(5) - self._view.updateStatus(_("System upgrade is complete.")) - # FIXME should we look into /var/run/reboot-required here? - if self._view.confirmRestart(): - subprocess.call(["reboot"]) - - def run(self): - self.edgyUpgrade() - - diff --git a/DistUpgrade/DistUpgradeView.py b/DistUpgrade/DistUpgradeView.py deleted file mode 100644 index 109a278b..00000000 --- a/DistUpgrade/DistUpgradeView.py +++ /dev/null @@ -1,122 +0,0 @@ -# DistUpgradeView.py -# -# Copyright (c) 2004,2005 Canonical -# -# Author: Michael Vogt <michael.vogt@ubuntu.com> -# -# This program is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -# USA - -from gettext import gettext as _ - -def FuzzyTimeToStr(sec): - " return the time a bit fuzzy (no seconds if time > 60 secs " - if sec > 60*60*24: - return _("%li days %li hours %li minutes") % (sec/60/60/24, (sec/60/60) % 24, (sec/60) % 60) - if sec > 60*60: - return _("%li hours %li minutes") % (sec/60/60, (sec/60) % 60) - if sec > 60: - return _("%li minutes") % (sec/60) - return _("%li seconds") % sec - -def estimatedDownloadTime(requiredDownload): - """ get the estimated download time """ - timeModem = requiredDownload/(56*1024/8) # 56 kbit - timeDSL = requiredDownload/(1024*1024/8) # 1Mbit = 1024 kbit - s= _("This download will take about %s with a 1Mbit DSL connection " - "and about %s with a 56k modem" % (FuzzyTimeToStr(timeDSL),FuzzyTimeToStr(timeModem))) - return s - - -class DumbTerminal(object): - def call(self, cmd): - " expects a command in the subprocess style (as a list) " - import subprocess - subprocess.call(cmd) - - -(STEP_PREPARE, - STEP_MODIFY_SOURCES, - STEP_FETCH_INSTALL, - STEP_CLEANUP, - STEP_REBOOT) = range(1,6) - -class DistUpgradeView(object): - " abstraction for the upgrade view " - def __init__(self): - pass - def getOpCacheProgress(self): - " return a OpProgress() subclass for the given graphic" - return apt.progress.OpProgress() - def getFetchProgress(self): - " return a fetch progress object " - return apt.progress.FetchProgress() - def getInstallProgress(self, cache=None): - " return a install progress object " - return apt.progress.InstallProgress(cache) - def getTerminal(self): - return DumbTerminal() - def updateStatus(self, msg): - """ update the current status of the distUpgrade based - on the current view - """ - pass - def abort(): - """ provide a visual feedback that the upgrade was aborted """ - pass - def setStep(self, step): - """ we have 5 steps current for a upgrade: - 1. Analyzing the system - 2. Updating repository information - 3. Performing the upgrade - 4. Post upgrade stuff - 5. Complete - """ - pass - def hideStep(self, step): - " hide a certain step from the GUI " - pass - def confirmChanges(self, summary, changes, downloadSize, actions=None): - """ display the list of changed packages (apt.Package) and - return if the user confirms them - """ - self.toInstall = [] - self.toUpgrade = [] - self.toRemove = [] - self.toDowngrade = [] - for pkg in changes: - if pkg.markedInstall: self.toInstall.append(pkg.name) - elif pkg.markedUpgrade: self.toUpgrade.append(pkg.name) - elif pkg.markedDelete: self.toRemove.append(pkg.name) - elif pkg.markedDowngrade: self.toDowngrade.append(pkg.name) - # no re-installs - assert(len(self.toInstall)+len(self.toUpgrade)+len(self.toRemove)+len(self.toDowngrade) == len(changes)) - def askYesNoQuestion(self, summary, msg): - " ask a Yes/No question and return True on 'Yes' " - pass - def confirmRestart(self): - " generic ask about the restart, can be overriden " - summary = _("Reboot required") - msg = _("The upgrade is finished and " - "a reboot is required. " - "Do you want to do this " - "now?") - return self.askYesNoQuestion(summary, msg) - def error(self, summary, msg, extended_msg=None): - " display a error " - pass - def information(self, summary, msg, extended_msg=None): - " display a information msg" - pass diff --git a/DistUpgrade/DistUpgradeViewGtk.py b/DistUpgrade/DistUpgradeViewGtk.py deleted file mode 100644 index 07a94110..00000000 --- a/DistUpgrade/DistUpgradeViewGtk.py +++ /dev/null @@ -1,634 +0,0 @@ -# DistUpgradeViewGtk.py -# -# Copyright (c) 2004-2006 Canonical -# -# Author: Michael Vogt <michael.vogt@ubuntu.com> -# -# This program is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -# USA - -import pygtk -pygtk.require('2.0') -import gtk -import gtk.gdk -import gtk.glade -import vte -import gobject -import pango -import sys -import logging -import time -import subprocess - -import apt -import apt_pkg -import os - -from apt.progress import InstallProgress -from DistUpgradeView import DistUpgradeView, FuzzyTimeToStr, estimatedDownloadTime -from UpdateManager.Common.SimpleGladeApp import SimpleGladeApp, bindtextdomain - -import gettext -from gettext import gettext as _ - -def utf8(str): - return unicode(str, 'latin1').encode('utf-8') - - -class GtkCdromProgressAdapter(apt.progress.CdromProgress): - """ Report the cdrom add progress - Subclass this class to implement cdrom add progress reporting - """ - def __init__(self, parent): - self.status = parent.label_status - self.progress = parent.progressbar_cache - self.parent = parent - def update(self, text, step): - """ update is called regularly so that the gui can be redrawn """ - if text: - self.status.set_text(text) - self.progress.set_fraction(step/float(self.totalSteps)) - while gtk.events_pending(): - gtk.main_iteration() - def askCdromName(self): - return (False, "") - def changeCdrom(self): - return False - -class GtkOpProgress(apt.progress.OpProgress): - def __init__(self, progressbar): - self.progressbar = progressbar - #self.progressbar.set_pulse_step(0.01) - #self.progressbar.pulse() - - def update(self, percent): - #if percent > 99: - # self.progressbar.set_fraction(1) - #else: - # self.progressbar.pulse() - self.progressbar.set_fraction(percent/100.0) - while gtk.events_pending(): - gtk.main_iteration() - - def done(self): - self.progressbar.set_text(" ") - - -class GtkFetchProgressAdapter(apt.progress.FetchProgress): - # FIXME: we really should have some sort of "we are at step" - # xy in the gui - # FIXME2: we need to thing about mediaCheck here too - def __init__(self, parent): - # if this is set to false the download will cancel - self.status = parent.label_status - self.progress = parent.progressbar_cache - self.parent = parent - def mediaChange(self, medium, drive): - #print "mediaChange %s %s" % (medium, drive) - msg = _("Please insert '%s' into the drive '%s'") % (medium,drive) - dialog = gtk.MessageDialog(parent=self.parent.window_main, - flags=gtk.DIALOG_MODAL, - type=gtk.MESSAGE_QUESTION, - buttons=gtk.BUTTONS_OK_CANCEL) - dialog.set_markup(msg) - res = dialog.run() - #print res - dialog.destroy() - if res == gtk.RESPONSE_OK: - return True - return False - def start(self): - #self.progress.show() - self.progress.set_fraction(0) - self.status.show() - def stop(self): - self.progress.set_text(" ") - self.status.set_text(_("Fetching is complete")) - def pulse(self): - # FIXME: move the status_str and progress_str into python-apt - # (python-apt need i18n first for this) - apt.progress.FetchProgress.pulse(self) - self.progress.set_fraction(self.percent/100.0) - currentItem = self.currentItems + 1 - if currentItem > self.totalItems: - currentItem = self.totalItems - - if self.currentCPS > 0: - self.status.set_text(_("Fetching file %li of %li at %s/s") % (currentItem, self.totalItems, apt_pkg.SizeToStr(self.currentCPS))) - self.progress.set_text(_("About %s remaining") % FuzzyTimeToStr(self.eta)) - else: - self.status.set_text(_("Fetching file %li of %li") % (currentItem, self.totalItems)) - self.progress.set_text(" ") - - while gtk.events_pending(): - gtk.main_iteration() - return True - -class GtkInstallProgressAdapter(InstallProgress): - # timeout with no status change when the terminal is expanded - # automatically - TIMEOUT_TERMINAL_ACTIVITY = 240 - - def __init__(self,parent): - InstallProgress.__init__(self) - self._cache = None - self.label_status = parent.label_status - self.progress = parent.progressbar_cache - self.expander = parent.expander_terminal - self.term = parent._term - self.parent = parent - # setup the child waiting - reaper = vte.reaper_get() - reaper.connect("child-exited", self.child_exited) - # some options for dpkg to make it die less easily - apt_pkg.Config.Set("DPkg::Options::","--force-overwrite") - - def startUpdate(self): - self.finished = False - # FIXME: add support for the timeout - # of the terminal (to display something useful then) - # -> longer term, move this code into python-apt - self.label_status.set_text(_("Applying changes")) - self.progress.set_fraction(0.0) - self.progress.set_text(" ") - self.expander.set_sensitive(True) - self.term.show() - # if no libgnome2-perl is installed show the terminal - frontend="gnome" - if self._cache: - if not self._cache.has_key("libgnome2-perl") or \ - not self._cache["libgnome2-perl"].isInstalled: - frontend = "dialog" - self.expander.set_expanded(True) - self.env = ["VTE_PTY_KEEP_FD=%s"% self.writefd, - "DEBIAN_FRONTEND=%s" % frontend, - "APT_LISTCHANGES_FRONTEND=none"] - # do a bit of time-keeping - self.start_time = 0.0 - self.time_ui = 0.0 - self.last_activity = 0.0 - - def error(self, pkg, errormsg): - logging.error("got an error from dpkg for pkg: '%s': '%s'" % (pkg, errormsg)) - #self.expander_terminal.set_expanded(True) - self.parent.dialog_error.set_transient_for(self.parent.window_main) - summary = _("Could not install '%s'") % pkg - msg = _("The upgrade aborts now. Please report this bug against the 'update-manager' " - "package and include the files in /var/log/dist-upgrade/ in the bugreport.") - markup="<big><b>%s</b></big>\n\n%s" % (summary, msg) - self.parent.dialog_error.realize() - self.parent.dialog_error.window.set_functions(gtk.gdk.FUNC_MOVE) - self.parent.label_error.set_markup(markup) - self.parent.textview_error.get_buffer().set_text(utf8(errormsg)) - self.parent.scroll_error.show() - self.parent.dialog_error.run() - self.parent.dialog_error.hide() - - def conffile(self, current, new): - logging.debug("got a conffile-prompt from dpkg for file: '%s'" % current) - start = time.time() - #self.expander.set_expanded(True) - prim = _("Replace the customized configuration file\n'%s'?") % current - sec = _("You will lose any changes you have made to this " - "configuration file if you choose to replace it with " - "a newer version.") - markup = "<span weight=\"bold\" size=\"larger\">%s </span> \n\n%s" % (prim, sec) - self.parent.label_conffile.set_markup(markup) - self.parent.dialog_conffile.set_transient_for(self.parent.window_main) - - # now get the diff - if os.path.exists("/usr/bin/diff"): - cmd = ["/usr/bin/diff", "-u", current, new] - diff = utf8(subprocess.Popen(cmd, stdout=subprocess.PIPE).communicate()[0]) - self.parent.textview_conffile.get_buffer().set_text(diff) - else: - self.parent.textview_conffile.get_buffer().set_text(_("The 'diff' command was not found")) - res = self.parent.dialog_conffile.run() - self.parent.dialog_conffile.hide() - self.time_ui += time.time() - start - # if replace, send this to the terminal - if res == gtk.RESPONSE_YES: - self.term.feed_child("y\n") - else: - self.term.feed_child("n\n") - - def fork(self): - pid = self.term.forkpty(envv=self.env) - if pid == 0: - # HACK to work around bug in python/vte and unregister the logging - # atexit func in the child - sys.exitfunc = lambda: True - return pid - - def statusChange(self, pkg, percent, status): - # start the timer when the first package changes its status - if self.start_time == 0.0: - #print "setting start time to %s" % self.start_time - self.start_time = time.time() - self.progress.set_fraction(float(self.percent)/100.0) - self.label_status.set_text(status.strip()) - # start showing when we gathered some data - if percent > 1.0: - self.last_activity = time.time() - self.activity_timeout_reported = False - delta = self.last_activity - self.start_time - # time wasted in conffile questions (or other ui activity) - delta -= self.time_ui - time_per_percent = (float(delta)/percent) - eta = (100.0 - self.percent) * time_per_percent - # only show if we have some sensible data (60sec < eta < 2days) - if eta > 61.0 and eta < (60*60*24*2): - self.progress.set_text(_("About %s remaining") % FuzzyTimeToStr(eta)) - else: - self.progress.set_text(" ") - - def child_exited(self, term, pid, status): - self.apt_status = os.WEXITSTATUS(status) - self.finished = True - - def waitChild(self): - while not self.finished: - self.updateInterface() - return self.apt_status - - def finishUpdate(self): - self.label_status.set_text("") - - def updateInterface(self): - try: - InstallProgress.updateInterface(self) - except ValueError, e: - logging.error("got ValueError from InstallPrgoress.updateInterface. Line was '%s' (%s)" % (self.read, e)) - # reset self.read so that it can continue reading and does not loop - self.read = "" - # check if we haven't started yet with packages, pulse then - if self.start_time == 0.0: - self.progress.pulse() - time.sleep(0.2) - # check about terminal activity - if self.last_activity > 0 and \ - (self.last_activity + self.TIMEOUT_TERMINAL_ACTIVITY) < time.time(): - if not self.activity_timeout_reported: - logging.warning("no activity on terminal for %s seconds (%s)" % (self.TIMEOUT_TERMINAL_ACTIVITY, self.label_status.get_text())) - self.activity_timeout_reported = True - self.parent.expander_terminal.set_expanded(True) - while gtk.events_pending(): - gtk.main_iteration() - time.sleep(0.02) - -class DistUpgradeVteTerminal(object): - def __init__(self, parent, term): - self.term = term - self.parent = parent - def call(self, cmd): - def wait_for_child(widget): - #print "wait for child finished" - self.finished=True - self.term.show() - self.term.connect("child-exited", wait_for_child) - self.parent.expander_terminal.set_expanded(True) - self.term.fork_command(command=cmd[0],argv=cmd) - self.finished = False - while not self.finished: - while gtk.events_pending(): - gtk.main_iteration() - time.sleep(0.1) - del self.finished - -class DistUpgradeViewGtk(DistUpgradeView,SimpleGladeApp): - " gtk frontend of the distUpgrade tool " - def __init__(self, datadir=None): - if not datadir: - localedir=os.path.join(os.getcwd(),"mo") - gladedir=os.getcwd() - else: - localedir="/usr/share/locale/update-manager" - gladedir=os.path.join(datadir, "glade") - - # FIXME: i18n must be somewhere relative do this dir - try: - bindtextdomain("update-manager", localedir) - gettext.textdomain("update-manager") - except Exception, e: - logging.warning("Error setting locales (%s)" % e) - - icons = gtk.icon_theme_get_default() - try: - gtk.window_set_default_icon(icons.load_icon("update-manager", 32, 0)) - except gobject.GError, e: - logging.debug("error setting default icon, ignoring (%s)" % e) - pass - SimpleGladeApp.__init__(self, gladedir+"/DistUpgrade.glade", - None, domain="update-manager") - self.prev_step = 0 # keep a record of the latest step - # we dont use this currently - #self.window_main.set_keep_above(True) - self.icontheme = gtk.icon_theme_get_default() - # we keep a reference pngloader around so that its in memory - # -> this avoid the issue that during the dapper->edgy upgrade - # the loaders move from /usr/lib/gtk/2.4.0/loaders to 2.10.0 - self.pngloader = gtk.gdk.PixbufLoader("png") - - self.window_main.realize() - self.window_main.window.set_functions(gtk.gdk.FUNC_MOVE) - self._opCacheProgress = GtkOpProgress(self.progressbar_cache) - self._fetchProgress = GtkFetchProgressAdapter(self) - self._cdromProgress = GtkCdromProgressAdapter(self) - self._installProgress = GtkInstallProgressAdapter(self) - # details dialog - self.details_list = gtk.ListStore(gobject.TYPE_STRING) - column = gtk.TreeViewColumn("") - render = gtk.CellRendererText() - column.pack_start(render, True) - column.add_attribute(render, "markup", 0) - self.treeview_details.append_column(column) - self.treeview_details.set_model(self.details_list) - self.vscrollbar_terminal.set_adjustment(self._term.get_adjustment()) - # work around bug in VteTerminal here - self._term.realize() - - # Use italic style in the status labels - attrlist=pango.AttrList() - attr = pango.AttrStyle(pango.STYLE_ITALIC, 0, -1) - attrlist.insert(attr) - self.label_status.set_property("attributes", attrlist) - # reasonable fault handler - sys.excepthook = self._handleException - - def _handleException(self, type, value, tb): - import traceback - lines = traceback.format_exception(type, value, tb) - logging.error("not handled expection:\n%s" % "\n".join(lines)) - self.error(_("A fatal error occured"), - _("Please report this as a bug and include the " - "files /var/log/dist-upgrade/main.log and " - "/var/log/dist-upgrade/apt.log " - "in your report. The upgrade aborts now.\n" - "Your original sources.list was saved in " - "/etc/apt/sources.list.distUpgrade."), - "\n".join(lines)) - sys.exit(1) - - def getTerminal(self): - return DistUpgradeVteTerminal(self, self._term) - - def create_terminal(self, arg1,arg2,arg3,arg4): - " helper to create a vte terminal " - self._term = vte.Terminal() - self._term.set_font_from_string("monospace 10") - self._term.connect("contents-changed", self._term_content_changed) - self._terminal_lines = [] - try: - self._terminal_log = open("/var/log/dist-upgrade/term.log","w") - except IOError: - # if something goes wrong (permission denied etc), use stdout - self._terminal_log = sys.stdout - return self._term - - def _term_content_changed(self, term): - " called when the *visible* part of the terminal changes " - - # get the current visible text, - current_text = self._term.get_text(lambda a,b,c,d: True) - # see what we have currently and only print stuff that wasn't - # visible last time - new_lines = [] - for line in current_text.split("\n"): - new_lines.append(line) - if not line in self._terminal_lines: - self._terminal_log.write(line+"\n") - self._terminal_log.flush() - self._terminal_lines = new_lines - def getFetchProgress(self): - return self._fetchProgress - def getInstallProgress(self, cache): - self._installProgress._cache = cache - return self._installProgress - def getOpCacheProgress(self): - return self._opCacheProgress - def getCdromProgress(self): - return self._cdromProgress - def updateStatus(self, msg): - self.label_status.set_text("%s" % msg) - def hideStep(self, step): - image = getattr(self,"image_step%i" % step) - label = getattr(self,"label_step%i" % step) - image.hide() - label.hide() - def abort(self): - size = gtk.ICON_SIZE_MENU - step = self.prev_step - if step > 0: - image = getattr(self,"image_step%i" % step) - arrow = getattr(self,"arrow_step%i" % step) - image.set_from_stock(gtk.STOCK_CANCEL, size) - image.show() - arrow.hide() - def setStep(self, step): - if self.icontheme.rescan_if_needed(): - logging.debug("icon theme changed, re-reading") - # first update the "previous" step as completed - size = gtk.ICON_SIZE_MENU - attrlist=pango.AttrList() - if self.prev_step: - image = getattr(self,"image_step%i" % self.prev_step) - label = getattr(self,"label_step%i" % self.prev_step) - arrow = getattr(self,"arrow_step%i" % self.prev_step) - label.set_property("attributes",attrlist) - image.set_from_stock(gtk.STOCK_APPLY, size) - image.show() - arrow.hide() - self.prev_step = step - # show the an arrow for the current step and make the label bold - image = getattr(self,"image_step%i" % step) - label = getattr(self,"label_step%i" % step) - arrow = getattr(self,"arrow_step%i" % step) - arrow.show() - image.hide() - attr = pango.AttrWeight(pango.WEIGHT_BOLD, 0, -1) - attrlist.insert(attr) - label.set_property("attributes",attrlist) - - def information(self, summary, msg, extended_msg=None): - self.dialog_information.set_transient_for(self.window_main) - msg = "<big><b>%s</b></big>\n\n%s" % (summary,msg) - self.label_information.set_markup(msg) - if extended_msg != None: - buffer = self.textview_information.get_buffer() - buffer.set_text(extended_msg) - self.scroll_information.show() - else: - self.scroll_information.hide() - self.dialog_information.realize() - self.dialog_information.window.set_functions(gtk.gdk.FUNC_MOVE) - self.dialog_information.run() - self.dialog_information.hide() - while gtk.events_pending(): - gtk.main_iteration() - - def error(self, summary, msg, extended_msg=None): - self.dialog_error.set_transient_for(self.window_main) - #self.expander_terminal.set_expanded(True) - msg="<big><b>%s</b></big>\n\n%s" % (summary, msg) - self.label_error.set_markup(msg) - if extended_msg != None: - buffer = self.textview_error.get_buffer() - buffer.set_text(extended_msg) - self.scroll_error.show() - else: - self.scroll_error.hide() - self.dialog_error.realize() - self.dialog_error.window.set_functions(gtk.gdk.FUNC_MOVE) - self.dialog_error.run() - self.dialog_error.hide() - return False - - def confirmChanges(self, summary, changes, downloadSize, actions=None): - # FIXME: add a whitelist here for packages that we expect to be - # removed (how to calc this automatically?) - DistUpgradeView.confirmChanges(self, summary, changes, downloadSize) - pkgs_remove = len(self.toRemove) - pkgs_inst = len(self.toInstall) - pkgs_upgrade = len(self.toUpgrade) - msg = "" - - if pkgs_remove > 0: - # FIXME: make those two seperate lines to make it clear - # that the "%" applies to the result of ngettext - msg += gettext.ngettext("%d package is going to be removed.", - "%d packages are going to be removed.", - pkgs_remove) % pkgs_remove - msg += " " - if pkgs_inst > 0: - msg += gettext.ngettext("%d new package is going to be " - "installed.", - "%d new packages are going to be " - "installed.",pkgs_inst) % pkgs_inst - msg += " " - if pkgs_upgrade > 0: - msg += gettext.ngettext("%d package is going to be upgraded.", - "%d packages are going to be upgraded.", - pkgs_upgrade) % pkgs_upgrade - msg +=" " - if downloadSize > 0: - msg += _("\n\nYou have to download a total of %s. ") %\ - apt_pkg.SizeToStr(downloadSize) - msg += estimatedDownloadTime(downloadSize) - msg += "." - - if (pkgs_upgrade + pkgs_inst + pkgs_remove) > 100: - msg += "\n\n%s" % _("Fetching and installing the upgrade can take several hours and "\ - "cannot be canceled at any time later.") - - msg += "\n\n<b>%s</b>" % _("To prevent data loss close all open "\ - "applications and documents.") - - # Show an error if no actions are planned - if (pkgs_upgrade + pkgs_inst + pkgs_remove) < 1: - # FIXME: this should go into DistUpgradeController - summary = _("Your system is up-to-date") - msg = _("There are no upgrades available for your system. " - "The upgrade will now be canceled.") - self.error(summary, msg) - return False - - if actions != None: - self.button_cancel_changes.set_use_stock(False) - self.button_cancel_changes.set_use_underline(True) - self.button_cancel_changes.set_label(actions[0]) - self.button_confirm_changes.set_label(actions[1]) - - self.label_summary.set_markup("<big><b>%s</b></big>" % summary) - self.label_changes.set_markup(msg) - # fill in the details - self.details_list.clear() - for rm in self.toRemove: - self.details_list.append([_("<b>Remove %s</b>") % rm]) - for inst in self.toInstall: - self.details_list.append([_("Install %s") % inst]) - for up in self.toUpgrade: - self.details_list.append([_("Upgrade %s") % up]) - self.treeview_details.scroll_to_cell((0,)) - self.dialog_changes.set_transient_for(self.window_main) - self.dialog_changes.realize() - self.dialog_changes.window.set_functions(gtk.gdk.FUNC_MOVE) - res = self.dialog_changes.run() - self.dialog_changes.hide() - if res == gtk.RESPONSE_YES: - return True - return False - - def askYesNoQuestion(self, summary, msg): - msg = "<big><b>%s</b></big>\n\n%s" % (summary,msg) - dialog = gtk.MessageDialog(parent=self.window_main, - flags=gtk.DIALOG_MODAL, - type=gtk.MESSAGE_QUESTION, - buttons=gtk.BUTTONS_YES_NO) - dialog.set_markup(msg) - res = dialog.run() - dialog.destroy() - if res == gtk.RESPONSE_YES: - return True - return False - - def confirmRestart(self): - self.dialog_restart.set_transient_for(self.window_main) - self.dialog_restart.realize() - self.dialog_restart.window.set_functions(gtk.gdk.FUNC_MOVE) - res = self.dialog_restart.run() - self.dialog_restart.hide() - if res == gtk.RESPONSE_YES: - return True - return False - - def on_window_main_delete_event(self, widget, event): - self.dialog_cancel.set_transient_for(self.window_main) - self.dialog_cancel.realize() - self.dialog_cancel.window.set_functions(gtk.gdk.FUNC_MOVE) - res = self.dialog_cancel.run() - self.dialog_cancel.hide() - if res == gtk.RESPONSE_CANCEL: - #FIXME: this does not work correctly and leaves a stalled - # dist-upgrade.py process - self.destroy() - return True - -if __name__ == "__main__": - - view = DistUpgradeViewGtk() - fp = GtkFetchProgressAdapter(view) - ip = GtkInstallProgressAdapter(view) - - cache = apt.Cache() - for pkg in sys.argv[1:]: - cache[pkg].markInstall() - cache.commit(fp,ip) - sys.exit(0) - - #sys.exit(0) - ip.conffile("TODO","TODO~") - view.getTerminal().call(["dpkg","--configure","-a"]) - #view.getTerminal().call(["ls","-R","/usr"]) - view.error("short","long", - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - ) - view.confirmChanges("xx",[], 100) - diff --git a/DistUpgrade/DistUpgradeViewNonInteractive.py b/DistUpgrade/DistUpgradeViewNonInteractive.py deleted file mode 100644 index dbf38387..00000000 --- a/DistUpgrade/DistUpgradeViewNonInteractive.py +++ /dev/null @@ -1,78 +0,0 @@ -# DistUpgradeView.py -# -# Copyright (c) 2004,2005 Canonical -# -# Author: Michael Vogt <michael.vogt@ubuntu.com> -# -# This program is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -# USA - -import apt -import logging -import time -from DistUpgradeView import DistUpgradeView - -class NonInteractiveInstallProgress(apt.progress.InstallProgress): - def error(self, pkg, errormsg): - logging.error("got a error from dpkg for pkg: '%s': '%s'" % (pkg, errormsg)) - def conffile(self, current, new): - logging.debug("got a conffile-prompt from dpkg for file: '%s'" % current) - def updateInterface(self): - apt.progress.InstallProgress.updateInterface(self) - time.sleep(0.001) - -class DistUpgradeViewNonInteractive(DistUpgradeView): - " non-interactive version of the upgrade view " - def __init__(self): - pass - def getOpCacheProgress(self): - " return a OpProgress() subclass for the given graphic" - return apt.progress.OpProgress() - def getFetchProgress(self): - " return a fetch progress object " - return apt.progress.FetchProgress() - def getInstallProgress(self): - " return a install progress object " - return NonInteractiveInstallProgress() - def updateStatus(self, msg): - """ update the current status of the distUpgrade based - on the current view - """ - pass - def setStep(self, step): - """ we have 5 steps current for a upgrade: - 1. Analyzing the system - 2. Updating repository information - 3. Performing the upgrade - 4. Post upgrade stuff - 5. Complete - """ - pass - def confirmChanges(self, summary, changes, downloadSize, actions=None): - DistUpgradeView.confirmChanges(self, summary, changes, downloadSize, actions) - logging.debug("toinstall: '%s'" % self.toInstall) - logging.debug("toupgrade: '%s'" % self.toUpgrade) - logging.debug("toremove: '%s'" % self.toRemove) - return True - def askYesNoQuestion(self, summary, msg): - " ask a Yes/No question and return True on 'Yes' " - return True - def confirmRestart(self): - " generic ask about the restart, can be overriden " - return False - def error(self, summary, msg, extended_msg=None): - " display a error " - logging.error("%s %s (%s)" % (summary, msg, extended_msg)) - diff --git a/DistUpgrade/DistUpgradeViewText.py b/DistUpgrade/DistUpgradeViewText.py deleted file mode 100644 index b3bd61e3..00000000 --- a/DistUpgrade/DistUpgradeViewText.py +++ /dev/null @@ -1,196 +0,0 @@ -# DistUpgradeViewText.py -# -# Copyright (c) 2004-2006 Canonical -# -# Author: Michael Vogt <michael.vogt@ubuntu.com> -# -# This program is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 -# USA - -import sys -import logging -import time -import subprocess - -import apt -import apt_pkg -import os - -from apt.progress import InstallProgress -from DistUpgradeView import DistUpgradeView, FuzzyTimeToStr, estimatedDownloadTime - -import gettext -from gettext import gettext as _ - -class TextCdromProgressAdapter(apt.progress.CdromProgress): - """ Report the cdrom add progress """ - def update(self, text, step): - """ update is called regularly so that the gui can be redrawn """ - if text: - print "%s (%f)" % (text, step/float(self.totalSteps)*100) - def askCdromName(self): - return (False, "") - def changeCdrom(self): - return False - - -class DistUpgradeViewText(DistUpgradeView): - " text frontend of the distUpgrade tool " - def __init__(self, datadir=None): - if not datadir: - localedir=os.path.join(os.getcwd(),"mo") - else: - localedir="/usr/share/locale/update-manager" - - try: - gettext.bindtextdomain("update-manager", localedir) - gettext.textdomain("update-manager") - except Exception, e: - logging.warning("Error setting locales (%s)" % e) - - self.last_step = 0 # keep a record of the latest step - self._opCacheProgress = apt.progress.OpTextProgress() - self._fetchProgress = apt.progress.TextFetchProgress() - self._cdromProgress = TextCdromProgressAdapter() - self._installProgress = apt.progress.InstallProgress() - sys.excepthook = self._handleException - - def _handleException(self, type, value, tb): - import traceback - lines = traceback.format_exception(type, value, tb) - logging.error("not handled expection:\n%s" % "\n".join(lines)) - self.error(_("A fatal error occured"), - _("Please report this as a bug and include the " - "files /var/log/dist-upgrade/main.log and " - "/var/log/dist-upgrade/apt.log " - "in your report. The upgrade aborts now.\n" - "Your original sources.list was saved in " - "/etc/apt/sources.list.distUpgrade."), - "\n".join(lines)) - sys.exit(1) - - def getFetchProgress(self): - return self._fetchProgress - def getInstallProgress(self, cache): - self._installProgress._cache = cache - return self._installProgress - def getOpCacheProgress(self): - return self._opCacheProgress - def getCdromProgress(self): - return self._cdromProgress - def updateStatus(self, msg): - print msg - def abort(self): - print _("Aborting") - def setStep(self, step): - self.last_step = step - def information(self, summary, msg, extended_msg=None): - print summary - print msg - if extended_msg: - print extended_msg - def error(self, summary, msg, extended_msg=None): - print summary - print msg - if extended_msg: - print extended_msg - return False - def confirmChanges(self, summary, changes, downloadSize, actions=None): - DistUpgradeView.confirmChanges(self, summary, changes, downloadSize, actions) - pkgs_remove = len(self.toRemove) - pkgs_inst = len(self.toInstall) - pkgs_upgrade = len(self.toUpgrade) - msg = "" - - if pkgs_remove > 0: - # FIXME: make those two seperate lines to make it clear - # that the "%" applies to the result of ngettext - msg += gettext.ngettext("%d package is going to be removed.", - "%d packages are going to be removed.", - pkgs_remove) % pkgs_remove - msg += " " - if pkgs_inst > 0: - msg += gettext.ngettext("%d new package is going to be " - "installed.", - "%d new packages are going to be " - "installed.",pkgs_inst) % pkgs_inst - msg += " " - if pkgs_upgrade > 0: - msg += gettext.ngettext("%d package is going to be upgraded.", - "%d packages are going to be upgraded.", - pkgs_upgrade) % pkgs_upgrade - msg +=" " - if downloadSize > 0: - msg += _("\n\nYou have to download a total of %s. ") %\ - apt_pkg.SizeToStr(downloadSize) - msg += estimatedDownloadTime(downloadSize) - msg += "." - if (pkgs_upgrade + pkgs_inst + pkgs_remove) > 100: - msg += "\n\n%s" % _("Fetching and installing the upgrade can take several hours and "\ - "cannot be canceled at any time later.") - - # Show an error if no actions are planned - if (pkgs_upgrade + pkgs_inst + pkgs_remove) < 1: - # FIXME: this should go into DistUpgradeController - summary = _("Your system is up-to-date") - msg = _("There are no upgrades available for your system. " - "The upgrade will now be canceled.") - self.error(summary, msg) - return False - - return self.askYesNoQuestion(summary, msg) - - def askYesNoQuestion(self, summary, msg): - print summary - print msg - print _("Continue [Yn] "), - res = sys.stdin.readline() - if res.strip().lower().startswith("y"): - return True - return False - - def confirmRestart(self): - return self.askYesNoQuestion(_("Restart required"), - _("To fully ugprade, please restart")) - - -if __name__ == "__main__": - - view = DistUpgradeViewText() - view.confirmChanges("xx",[], 100) - sys.exit(0) - - fp = apt.progress.TextFetchProgress() - ip = apt.progress.InstallProgress() - - cache = apt.Cache() - for pkg in sys.argv[1:]: - cache[pkg].markInstall() - cache.commit(fp,ip) - - #sys.exit(0) - view.getTerminal().call(["dpkg","--configure","-a"]) - #view.getTerminal().call(["ls","-R","/usr"]) - view.error("short","long", - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - "asfds afsdj af asdf asdf asf dsa fadsf asdf as fasf sextended\n" - ) - view.confirmChanges("xx",[], 100) - print view.askYesNoQuestion("hello", "Icecream?") diff --git a/DistUpgrade/README b/DistUpgrade/README deleted file mode 100644 index b9d6c5d2..00000000 --- a/DistUpgrade/README +++ /dev/null @@ -1,62 +0,0 @@ -General -------- - -The dist-upgrader is designed to make upgrades for ubuntu (or similar -distributions) easy and painless. It supports both network mode and -cdrom upgrades. The cdromupgrade will ask if it should use the network -or not. There is a wrapper script "cdromugprade" (that assumes the -file of the upgrade life in -CDROM_ROOT/dists/stable/dist-upgrader/binary-all/) that can be put -onto the CD and it will support upgrades directly from the CD. - - -Configuration -------------- - -The DistUpgrade.cfg format is based on the python ConfigParser. - -It supports the following sections: - -[View] - controls the output - -[Distro] - global distribution specfic options -BaseMetaPkgs: - the basic meta-pkgs that must be installed (ubuntu-base usually) -MetaPkgs: - packages that define a "desktop" (e.g. ubuntu-desktop) -PostUpgrade{Install,Remove,Purge}: - action right after the upgrade was calculated in the cache (marking - happens *before* the cache.commit()) -ForcedObsoletes: - Obsolete packages that the user is asked about after the upgrade (marking - happens *after* the cache.commit()) -RemoveEssentialOk: - Those packages are ok to remove even though they are essential -KeepInstalledPkgs: - If the package was installed before, it should still be installed - after the upgrade -KeepInstalledSection: - Packages from this section that were installed should always be - installed afterwards as well (useful for eg translations) - -[$meta-pkg] -KeyDependencies: - Dependencies that are considered "key" dependencies of the meta-pkg to - detect if it was installed but later removed by the user -PostUpgrade{Install,Remove,Purge}: - s.above -ForcedObsoletes: - s.above - -[Files] - file specific stuff - -[Sources] - how to rewrite the sources.list - -[Network] - network specific options - -[Backports] - use specific packages for dist-upgrade -Packages= List of what packages to look for -VersionIdent=Version identification. needs to be uniq, dist-upgrader will - fetch the version that contains this string -SourcesList=a sources.list fragment that will be placed into - /etc/apt/sources.list.d and that contains the backported pkgs
\ No newline at end of file diff --git a/DistUpgrade/ReleaseAnnouncement b/DistUpgrade/ReleaseAnnouncement deleted file mode 100644 index 6d9adb2c..00000000 --- a/DistUpgrade/ReleaseAnnouncement +++ /dev/null @@ -1,50 +0,0 @@ -Welcome to Ubuntu 6.10 'Edgy Eft' ---------------------------------- - -*WARNING: THIS IS A BETA RELEASE* - -The Ubuntu team is proud to announce Ubuntu 6.10 'Edgy Eft'. - -Ubuntu is a Linux distribution for your desktop or server, with a fast -and easy install, regular releases, a tight selection of excellent -applications installed by default, and almost any other software you -can imagine available through the network. - -We hope you enjoy Ubuntu. - -Feedback and Helping --------------------- - -If you would like to help shape Ubuntu, take a look at the list of -ways you can participate at - - http://www.ubuntu.com/community/participate/ - -Your comments, bug reports, patches and suggestions will help ensure -that our next release is the best release of Ubuntu ever. Please -report bugs through Launchpad: - - http://launchpad.net/distros/ubuntu/+bugs - -If you have a question, or if you think you may have found a bug but -aren't sure, first try asking on the #ubuntu IRC channel on Freenode, -on the Ubuntu Users mailing list, or on the Ubuntu forums: - - http://lists.ubuntu.com/mailman/listinfo/ubuntu-users - http://www.ubuntuforums.org/ - - -More Information ----------------- - -You can find out more about Ubuntu on our website, IRC channel and wiki. -If you're new to Ubuntu, please visit: - - http://www.ubuntu.com/ - - -To sign up for future Ubuntu announcements, please subscribe to Ubuntu's -very low volume announcement list at: - - http://lists.ubuntu.com/mailman/listinfo/ubuntu-announce - diff --git a/DistUpgrade/TODO b/DistUpgrade/TODO deleted file mode 100644 index e420d56b..00000000 --- a/DistUpgrade/TODO +++ /dev/null @@ -1,61 +0,0 @@ -CDROM: ------ - * release notes display in CDROM mode - * if run from CDROM and we have network -> do a self update - * support dapper-commercial in sources.list rewriting - * after "no-network" dist-upgrade it is most likely that the system - is only half-upgraded and update-manager will not be able to do - the full upgrade. update-manager needs to be changed to support - full dist-upgrades (possible by just calling the dist-upgrader - in a special mode) - -Misc: ------ - -* [fabbio]: we probably don't want to remove stuff that moved from main - to universe (if the user has only main enabled this is considered - obsolete). It would also be nice inform about packages that went from - main->universe. We could ship a list of demotions. -* set bigger timeout than 120s? - -breezy->dapper --------------- -- gnome-icon-theme changes a lot, icons move from hicolor to gnome. - this might have caused a specatular crash during a upgrade - - -hoary->breezy -------------- -- stop gnome-volume-manager before the hoary->breezy upgrade - (it will crash otherwise) -- send a "\n" on the libc6 question on hoary->breezy - -general -------- -- whitelist removal (pattern? e.g. c102 -> c2a etc) and not - display it? - -Robustness: ------------ -- automatically comment out entires in the sources.list that fail to - fetch. - Trouble: apt doesn't provide a method to map from a line in th - sources.list to the indexFile and python-apt dosn't proivde a way to - get all the metaIndexes in sources.list, nor a way to get the - pkgIndexFiles from the metaIndexes (metaIndex is not available in - python-apt at all) - What we could do is to write DistUpgradeCache.update(), check the - DescURI for each failed item and guess from it what sources.list - line failed (e.g. uri.endswith("Sources{.bz2|.gz") -> deb-src, get - base-uri, find 'dists' in uri etc) - -- don't stop if a single pkg fails to upgrade: - - the problem here is apt, in apt-pkg/deb/dpkgpm.cc it will stop if - dpkg returns a non-zero exit code. The problem with this is of course - that this may happen in the middle of the upgrade, leaving half the - packages unpacked but not configured or loads of packages unconfigured. - One possible solution is to not stop in apt but try to continue as long - as possible. The problem here is that e.g. if libnoitfy0 explodes and - evolution, update-notifer depend on it, continuing means to evo and u-n - can't be upgraded and dpkg explodes on them too. This is not more worse - than what we have right now I guess. diff --git a/DistUpgrade/Ubuntu.info b/DistUpgrade/Ubuntu.info deleted file mode 120000 index 171be7e1..00000000 --- a/DistUpgrade/Ubuntu.info +++ /dev/null @@ -1 +0,0 @@ -../data/channels/Ubuntu.info
\ No newline at end of file diff --git a/DistUpgrade/__init__.py b/DistUpgrade/__init__.py deleted file mode 100644 index e69de29b..00000000 --- a/DistUpgrade/__init__.py +++ /dev/null diff --git a/DistUpgrade/aptsources.py b/DistUpgrade/aptsources.py deleted file mode 120000 index 3cadeee7..00000000 --- a/DistUpgrade/aptsources.py +++ /dev/null @@ -1 +0,0 @@ -../UpdateManager/Common/aptsources.py
\ No newline at end of file diff --git a/DistUpgrade/backport-source.list b/DistUpgrade/backport-source.list deleted file mode 100644 index 5945e218..00000000 --- a/DistUpgrade/backport-source.list +++ /dev/null @@ -1,2 +0,0 @@ -# sources.list fragment for backported apt/dpkg/python-apt -deb http://people.ubuntu.com/~mvo/backports/dapper /
\ No newline at end of file diff --git a/DistUpgrade/build-dist.sh b/DistUpgrade/build-dist.sh deleted file mode 100755 index 4af768ef..00000000 --- a/DistUpgrade/build-dist.sh +++ /dev/null @@ -1,53 +0,0 @@ -#!/bin/sh - -# build a tarball that is ready for the upload. the format is -# simple, it contans: -# $version/$dist.tar.gz -# $version/ReleaseNotes -# this put into a file called "$dist-upgrader_$version.tar.gz" - - -TARGETDIR=../dist-upgrade-build -SOURCEDIR=`pwd` -DIST=edgy -MAINTAINER="Michael Vogt <michael.vogt@ubuntu.com>" -NOTES=ReleaseAnnouncement -version=$(date +%Y%m%d.%H%M) - -# create targetdir -if [ ! -d $TARGETDIR/$version ]; then - mkdir -p $TARGETDIR/$version -fi - -#build the actual dist-upgrader tarball -./build-tarball.sh - -# how move it into a container including the targetdir (with version) -# and ReleaeNotes -cd $TARGETDIR/$version -cp $SOURCEDIR/$NOTES . -cp $SOURCEDIR/$DIST.tar.gz . -cd .. - -# build it -TARBALL="dist-upgrader_"$version"_all.tar.gz" -tar czvf $TARBALL $version - -# now create a changes file -CHANGES="dist-upgrader_"$version"_all.changes" -echo > $CHANGES -echo "Origin: Ubuntu/$DIST" >> $CHANGES -echo "Format: 1.7" >> $CHANGES -echo "Date: `date -R`" >> $CHANGES -echo "Architecture: all">>$CHANGES -echo "Version: $version" >>$CHANGES -echo "Distribution: $DIST" >>$CHANGES -echo "Source: dist-upgrader" >> $CHANGES -echo "Binary: dist-upgrader" >> $CHANGES -echo "Urgency: low" >> $CHANGES -echo "Maintainer: $MAINTAINER" >> $CHANGES -echo "Changed-By: $MAINTAINER" >> $CHANGES -echo "Changes: " >> $CHANGES -echo " * new upstream version" >> $CHANGES -echo "Files: " >> $CHANGES -echo " `md5sum $TARBALL | awk '{print $1}'` `stat --format=%s $TARBALL` raw-dist-upgrader - $TARBALL" >> $CHANGES diff --git a/DistUpgrade/build-tarball.sh b/DistUpgrade/build-tarball.sh deleted file mode 100755 index 241eda06..00000000 --- a/DistUpgrade/build-tarball.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/sh - -DIST=edgy - -# cleanup -echo "Cleaning up" -rm -f *~ *.bak *.pyc *.moved '#'* *.rej *.orig -sudo rm -rf backports/ profile/ result/ tarball/ *.deb - - -# update po -(cd ../po; make update-po) - -# copy the mo files -cp -r ../po/mo . - -# make symlink -if [ ! -h $DIST ]; then - ln -s dist-upgrade.py $DIST -fi - -# create the tarball, copy links in place -tar -c -h -z -v --exclude=$DIST.tar.gz --exclude=$0 -f $DIST.tar.gz . - - diff --git a/DistUpgrade/cdromupgrade b/DistUpgrade/cdromupgrade deleted file mode 100755 index 37335045..00000000 --- a/DistUpgrade/cdromupgrade +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh -# -# "cdromupgrade" is a shell script wrapper around the dist-upgrader -# to make it possible to put it onto the top-level dir of a CD and -# run it from there -# -# Not that useful unfortunately when the CD is mounted "noexec", -# but useful for the notification-daemon that will just run it -# and be done with it -# -# WARNING: make sure to call it with a absolute path! -# (e.g. /cdrom/cdromugprade) - -CODENAME=edgy -UPGRADER_DIR=dists/stable/main/dist-upgrader/binary-all/ - -cddirname=${0%\/*} -fullpath=$cddirname/$UPGRADER_DIR - -# extrace the tar to a TMPDIR and run it from there -if [ ! -f $fullpath/$CODENAME.tar.gz ]; then - echo "Could not find the upgrade application archive, exiting" - exit 1 -fi - -TMPDIR=$(mktemp -d) -cd $TMPDIR -tar xzf $fullpath/$CODENAME.tar.gz -if [ ! -x $TMPDIR/$CODENAME ]; then - echo "Could not find the upgrade application in the archive, exiting" - exit 1 -fi -gksu -- $TMPDIR/$CODENAME --cdrom $cddirname diff --git a/DistUpgrade/data/breezy-rm.whitelist b/DistUpgrade/data/breezy-rm.whitelist deleted file mode 100644 index bd7fbbc7..00000000 --- a/DistUpgrade/data/breezy-rm.whitelist +++ /dev/null @@ -1,30 +0,0 @@ -# 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 -libesd0 # " by libesd-alsa0 -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 -libmyspell3 # " by libmyspell3c2 -libnautilus-burn1 # " by libnautilus-burn2 -libopenh323-1.15.2 # " by libopenh323-1.15.2c2 -libostyle1 # " by libostyle1c2 -libpt-1.8.3 # " by libpt-1.8.3c2 -libsmpeg0 # " by libsmpeg0c2 -libstlport4.6 # " by libstlport4.6c2 -libsp1 # " by libsp1c2 -openoffice.org-thesaurus-en-us # conflicts with openoofice.org2-core -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 diff --git a/DistUpgrade/demoted.cfg b/DistUpgrade/demoted.cfg deleted file mode 120000 index 0f19ba43..00000000 --- a/DistUpgrade/demoted.cfg +++ /dev/null @@ -1 +0,0 @@ -../utils/demoted.cfg
\ No newline at end of file diff --git a/DistUpgrade/dist-upgrade.py b/DistUpgrade/dist-upgrade.py deleted file mode 100755 index ff2fb933..00000000 --- a/DistUpgrade/dist-upgrade.py +++ /dev/null @@ -1,45 +0,0 @@ -#!/usr/bin/python2.4 - -from DistUpgradeControler import DistUpgradeControler -from DistUpgradeConfigParser import DistUpgradeConfig -import logging -import os -import sys -from optparse import OptionParser - -if __name__ == "__main__": - - parser = OptionParser() - parser.add_option("-c", "--cdrom", dest="cdromPath", default=None, - help="Use the given path to search for a cdrom with upgradable packages") - parser.add_option("--have-backports", dest="haveBackports", - action="store_true", default=False) - parser.add_option("--with-network", dest="withNetwork",action="store_true") - parser.add_option("--without-network", dest="withNetwork",action="store_false") - (options, args) = parser.parse_args() - - if not os.path.exists("/var/log/dist-upgrade"): - os.mkdir("/var/log/dist-upgrade") - logging.basicConfig(level=logging.DEBUG, - filename="/var/log/dist-upgrade/main.log", - format='%(asctime)s %(levelname)s %(message)s', - filemode='w') - - config = DistUpgradeConfig(".") - requested_view= config.get("View","View") - try: - view_modul = __import__(requested_view) - view_class = getattr(view_modul, requested_view) - view = view_class() - except (ImportError, AttributeError): - logging.error("can't import view '%s'" % requested_view) - print "can't find %s" % requested_view - sys.exit(1) - app = DistUpgradeControler(view, options) - - app.run() - - # testcode to see if the bullets look nice in the dialog - #for i in range(4): - # view.setStep(i+1) - # app.openCache() diff --git a/DistUpgrade/mirrors.cfg b/DistUpgrade/mirrors.cfg deleted file mode 100644 index 7ab0826c..00000000 --- a/DistUpgrade/mirrors.cfg +++ /dev/null @@ -1,282 +0,0 @@ -#ubuntu -http://archive.ubuntu.com/ubuntu -http://security.ubuntu.com/ubuntu -ftp://archive.ubuntu.com/ubuntu -ftp://security.ubuntu.com/ubuntu - -##===Australia=== -http://ftp.iinet.net.au/pub/ubuntu/ -http://mirror.optus.net/ubuntu/ -http://mirror.isp.net.au/ftp/pub/ubuntu/ -http://www.planetmirror.com/pub/ubuntu/ -http://ftp.filearena.net/pub/ubuntu/ -http://mirror.pacific.net.au/linux/ubuntu/ -ftp://mirror.isp.net.au/pub/ubuntu/ -ftp://ftp.planetmirror.com/pub/ubuntu/ -ftp://ftp.filearena.net/pub/ubuntu/ -ftp://mirror.internode.on.net/pub/ubuntu/ubuntu(InternodeCustomersonly) -ftp://ftp.iinet.net.au/pub/ubuntu/ -ftp://mirror.pacific.net.au/linux/ubuntu/ -rsync://ftp.iinet.net.au/ubuntu/ -rsync://mirror.isp.net.au/ubuntu -rsync://rsync.filearena.net/ubuntu/ - -##===Austria=== -http://ubuntu.inode.at/ubuntu/ -http://ubuntu.uni-klu.ac.at/ubuntu/ -http://gd.tuwien.ac.at/opsys/linux/ubuntu/archive/ -ftp://ubuntu.inode.at/ubuntu/ -ftp://ftp.uni-klu.ac.at/linux/ubuntu/ -ftp://gd.tuwien.ac.at/opsys/linux/ubuntu/archive/ -rsync://ubuntu.inode.at/ubuntu/ubuntu/ -rsync://gd.tuwien.ac.at/ubuntu/archive/ - -#===Belgium=== -http://ftp.belnet.be/pub/mirror/ubuntu.com/ -http://ftp.belnet.be/packages/ubuntu/ubuntu -http://ubuntu.mirrors.skynet.be/pub/ubuntu.com/ -http://mirror.freax.be/ubuntu/archive.ubuntu.com/ -ftp://ftp.belnet.be/pub/mirror/ubuntu.com/ -ftp://ftp.belnet.be/packages/ubuntu/ubuntu -ftp://ubuntu.mirrors.skynet.be/pub/ubuntu.com/ - -#===Brazil=== -http://espelhos.edugraf.ufsc.br/ubuntu/ -http://ubuntu.interlegis.gov.br/archive/ -http://ubuntu.c3sl.ufpr.br/ubuntu/ - -#===Canada=== -ftp://ftp.cs.mun.ca/pub/mirror/ubuntu/ -rsync://rsync.cs.mun.ca/ubuntu/ -http://mirror.cpsc.ucalgary.ca/mirror/ubuntu.com/ -ftp://mirror.cpsc.ucalgary.ca/mirror/ubuntu.com/ -http://mirror.arcticnetwork.ca/pub/ubuntu/packages/ -ftp://mirror.arcticnetwork.ca/pub/ubuntu/packages/ -rsync://rsync.arcticnetwork.ca/ubuntu-packages - -#===China=== -http://archive.ubuntu.org.cn/ubuntu/ -http://debian.cn99.com/ubuntu/ -http://mirror.lupaworld.com/ubuntu/ - -#===CostaRica=== -http://ftp.ucr.ac.cr/ubuntu/ -ftp://ftp.ucr.ac.cr/pub/ubuntu/ - -#===CzechRepublic=== -http://archive.ubuntu.cz/ubuntu/ -ftp://archive.ubuntu.cz/ubuntu/ -http://ubuntu.supp.name/ubuntu/ - -#===Denmark=== -http://mirrors.dk.telia.net/ubuntu/ -http://mirrors.dotsrc.org/ubuntu/ -http://klid.dk/homeftp/ubuntu/ -ftp://mirrors.dk.telia.net/ubuntu/ -ftp://mirrors.dotsrc.org/ubuntu/ -ftp://klid.dk/ubuntu/ - -#===Estonia=== -http://ftp.estpak.ee/pub/ubuntu/ -ftp://ftp.estpak.ee/pub/ubuntu/ - -#===Finland=== -http://www.nic.funet.fi/pub/mirrors/archive.ubuntu.com/ -ftp://ftp.funet.fi/pub/mirrors/archive.ubuntu.com/ - -#===France=== -http://mir1.ovh.net/ubuntu/ubuntu/ -http://fr.archive.ubuntu.com/ubuntu/ -http://ftp.u-picardie.fr/pub/ubuntu/ubuntu/ -http://ftp.oleane.net/pub/ubuntu/ -ftp://mir1.ovh.net/ubuntu/ubuntu/ -ftp://fr.archive.ubuntu.com/ubuntu/ -ftp://ftp.u-picardie.fr/pub/ubuntu/ubuntu/ -ftp://ftp.proxad.net/mirrors/ftp.ubuntu.com/ubuntu/(slow) -ftp://ftp.oleane.net/pub/ubuntu/ -rsync://mir1.ovh.net/ubuntu/ubuntu/ - -#===Germany=== -http://debian.charite.de/ubuntu/ -http://ftp.inf.tu-dresden.de/os/linux/dists/ubuntu -http://www.artfiles.org/ubuntu.com -http://ftp.rz.tu-bs.de/pub/mirror/ubuntu-packages/ -http://ftp.join.uni-muenster.de/pub/mirrors/ftp.ubuntu.com/ubuntu/ -http://www.ftp.uni-erlangen.de/pub/mirrors/ubuntu/ -http://debian.tu-bs.de/ubuntu -ftp://debian.charite.de/ubuntu/ -ftp://ftp.fu-berlin.de/linux/ubuntu/ -ftp://ftp.rz.tu-bs.de/pub/mirror/ubuntu-packages/ -ftp://ftp.join.uni-muenster.de/pub/mirrors/ftp.ubuntu.com/ubuntu/ -ftp://ftp.uni-erlangen.de/pub/mirrors/ubuntu/ -ftp://debian.tu-bs.de/ubuntu -rsync://ftp.inf.tu-dresden.de/ubuntu -rsync://ftp.rz.tu-bs.de/pub/mirror/ubuntu-packages/ -rsync://ftp.join.uni-muenster.de/pub/mirrors/ftp.ubuntu.com/ubuntu/ -rsync://debian.tu-bs.de/ubuntu - -#===Greece=== -http://ftp.ntua.gr/pub/linux/ubuntu/ -ftp://ftp.ntua.gr/pub/linux/ubuntu/ - -#===Hungary=== -http://ftp.kfki.hu/linux/ubuntu/ -ftp://ftp.kfki.hu/pub/linux/ubuntu/ -ftp://ftp.fsn.hu/pub/linux/distributions/ubuntu/ - -#===Indonesia=== -http://komo.vlsm.org/ubuntu/ -http://kambing.vlsm.org/ubuntu/ -rsync://komo.vlsm.org/ubuntu/ -rsync://kambing.vlsm.org/ubuntu/ - -#===Iceland=== -http://ubuntu.odg.cc/ -http://ubuntu.lhi.is/ - -#===Ireland=== -http://ftp.esat.net/mirrors/archive.ubuntu.com/ -http://ftp.heanet.ie/pub/ubuntu/ -ftp://ftp.esat.net/mirrors/archive.ubuntu.com/ -ftp://ftp.heanet.ie/pub/ubuntu/ -rsync://ftp.esat.net/mirrors/archive.ubuntu.com/ -rsync://ftp.heanet.ie/pub/ubuntu/ - -#===Italy=== -http://ftp.linux.it/ubuntu/ -http://na.mirror.garr.it/mirrors/ubuntu-archive/ -ftp://ftp.linux.it/ubuntu/ -ftp://na.mirror.garr.it/mirrors/ubuntu-archive/ -rsync://na.mirror.garr.it/ubuntu-archive/ - -#===Japan=== -http://ubuntu.mithril-linux.org/archives/ - -#===Korea=== -http://mirror.letsopen.com/os/ubuntu/ -ftp://mirror.letsopen.com/os/ubuntu/ -http://ftp.kaist.ac.kr/pub/ubuntu/ -ftp://ftp.kaist.ac.kr/pub/ubuntu/ -rsync://ftp.kaist.ac.kr/ubuntu/ - -#===Latvia=== -http://ubuntu-arch.linux.edu.lv/ubuntu/ - -#===Lithuania=== -http://ftp.litnet.lt/pub/ubuntu/ -ftp://ftp.litnet.lt/pub/ubuntu/ - -#===Namibia=== -ftp://ftp.polytechnic.edu.na/pub/ubuntulinux/ - -#===Netherlands=== -http://ftp.bit.nl/ubuntu/(Movedtohttp://nl.archive.ubuntu.com/ubuntu/) -http://ubuntu.synssans.nl -ftp://ftp.bit.nl/ubuntu/(Movedtoftp://nl.archive.ubuntu.com/ubuntu/) -rsync://ftp.bit.nl/ubuntu/(Movedtorsync://nl.archive.ubuntu.com/ubuntu/) - -#===NewZealand=== -ftp://ftp.citylink.co.nz/ubuntu/(maynotbeaccessibleoutsideof.nz) - -#===Nicaragua=== -http://www.computacion.uni.edu.ni/iso/ubuntu/ - -#===Norway=== -http://mirror.trivini.no/ubuntu(Movedtohttp://no.archive.ubuntu.com/ubuntu/) -ftp://mirror.trivini.no/ubuntu(Movedtoftp://no.archive.ubuntu.com/ubuntu/) -ftp://ftp.uninett.no/linux/ubuntu -rsync://ftp.uninett.no/ubuntu - -#===Poland=== -http://ubuntulinux.mainseek.com/ubuntu/ -http://ubuntu.task.gda.pl/ubuntu/ -ftp://ubuntu.task.gda.pl/ubuntu/ -rsync://ubuntu.task.gda.pl/ubuntu/ - -#===Portugal=== -ftp://ftp.rnl.ist.utl.pt/ubuntu/ -http://darkstar.ist.utl.pt/ubuntu/archive/ -http://ubuntu.dcc.fc.up.pt/ - -#===Romania=== -http://ftp.iasi.roedu.net/mirrors/ubuntulinux.org/ubuntu/(fullmirror) -ftp://ftp.iasi.roedu.net/mirrors/ubuntulinux.org/ubuntu/(fullmirror) -rsync://ftp.iasi.roedu.net/ubuntu/(fullmirror) -http://ftp.lug.ro/ubuntu/(i386andamd64) -ftp://ftp.lug.ro/ubuntu/(i386andamd64) - -#===Russia=== -http://debian.nsu.ru/ubuntu/(i386andamd64) -ftp://debian.nsu.ru/ubuntu/(i386andamd64) - -#===SouthAfrica=== -ftp://ftp.is.co.za/ubuntu -ftp://ftp.leg.uct.ac.za/pub/linux/ubuntu -ftp://ftp.sun.ac.za/ftp/ubuntu/ - -#===Spain=== -ftp://ftp.um.es/mirror/ubuntu/ -ftp://ftp.ubuntu-es.org/ubuntu/ - -#===Sweden=== -http://ftp.acc.umu.se/mirror/ubuntu/ -ftp://ftp.se.linux.org/pub/Linux/distributions/ubuntu/ - -#===Switzerland=== -http://mirror.switch.ch/ftp/mirror/ubuntu/ -ftp://mirror.switch.ch/mirror/ubuntu/ - -#===Taiwan=== -http://apt.ubuntu.org.tw/ubuntu/ -ftp://apt.ubuntu.org.tw/ubuntu/ -http://apt.nc.hcc.edu.tw/pub/ubuntu/ -http://ubuntu.csie.ntu.edu.tw/ubuntu/ -ftp://apt.nc.hcc.edu.tw/pub/ubuntu/ -ftp://os.nchc.org.tw/ubuntu/ -ftp://ftp.ee.ncku.edu.tw/pub/ubuntu/ -rsync://ftp.ee.ncku.edu.tw/ubuntu/ -http://ftp.cse.yzu.edu.tw/ftp/Linux/Ubuntu/ubuntu/ -ftp://ftp.cse.yzu.edu.tw/Linux/Ubuntu/ubuntu/ - -#===Turkey=== -http://godel.cs.bilgi.edu.tr/mirror/ubuntu/(i386) -ftp://godel.cs.bilgi.edu.tr/ubuntu/(i386) - -#===UnitedKingdom=== -http://www.mirrorservice.org/sites/archive.ubuntu.com/ubuntu/ -ftp://ftp.mirrorservice.org/sites/archive.ubuntu.com/ubuntu/ -http://www.mirror.ac.uk/mirror/archive.ubuntu.com/ubuntu/ -ftp://ftp.mirror.ac.uk/mirror/archive.ubuntu.com/ubuntu/ -rsync://rsync.mirrorservice.org/archive.ubuntu.com/ubuntu/ -http://ubuntu.blueyonder.co.uk/archive/ -ftp://ftp.blueyonder.co.uk/sites/ubuntu/archive/ - -#===UnitedStates=== -http://mirror.cs.umn.edu/ubuntu/ -http://lug.mtu.edu/ubuntu/ -http://mirror.clarkson.edu/pub/distributions/ubuntu/ -http://ubuntu.mirrors.tds.net/ubuntu/ -http://www.opensourcemirrors.org/ubuntu/ -http://ftp.ale.org/pub/mirrors/ubuntu/ -http://ubuntu.secs.oakland.edu/ -http://mirror.mcs.anl.gov/pub/ubuntu/ -http://mirrors.cat.pdx.edu/ubuntu/ -http://ubuntu.cs.utah.edu/ubuntu/ -http://ftp.ussg.iu.edu/linux/ubuntu/ -http://mirrors.xmission.com/ubuntu/ -http://ftp.osuosl.org/pub/ubuntu/ -http://mirrors.cs.wmich.edu/ubuntu/ -ftp://ftp.osuosl.org/pub/ubuntu/ -ftp://mirrors.xmission.com/ubuntu/ -ftp://ftp.ussg.iu.edu/linux/ubuntu/ -ftp://mirror.clarkson.edu/pub/distributions/ubuntu/ -ftp://ubuntu.mirrors.tds.net/ubuntu/ -ftp://mirror.mcs.anl.gov/pub/ubuntu/ -ftp://mirrors.cat.pdx.edu/ubuntu/ -ftp://ubuntu.cs.utah.edu/pub/ubuntu/ubuntu/ -rsync://ubuntu.cs.utah.edu/ubuntu/ -rsync://mirrors.cat.pdx.edu/ubuntu/ -rsync://mirror.mcs.anl.gov/ubuntu/ -rsync://ubuntu.mirrors.tds.net/ubuntu/ -rsync://mirror.cs.umn.edu/ubuntu/ - diff --git a/DistUpgrade/removal_blacklist.cfg b/DistUpgrade/removal_blacklist.cfg deleted file mode 100644 index 7bfb114b..00000000 --- a/DistUpgrade/removal_blacklist.cfg +++ /dev/null @@ -1,9 +0,0 @@ -# blacklist of packages that should never be removed -ubuntu-standard -ubuntu-minimal -ubuntu-desktop -kubuntu-destkop -edubuntu-desktop -linux-image-.* -linux-restricted-.* -nvidia-glx.* |
