Utility for upgrading Pop!_OS and its recovery partition to new releases. This tool will be used
as a replacement for Ubuntu's do-release-upgrade
script. The goal is to be less error-prone,
ensuring that critical packages are retained on upgrade, and better integration with Pop!_OS.
When launched in daemon mode (requires root), a new Dbus service will be registered, with the following details:
com.system76.PopUpgrade
com.system76.PopUpgrade
/com/system76/PopUpgrade
FetchUpdates (additional_strings: as, download_only: b) -> (updates_available: b, completed: s, total: s)
completed
and total
will have non-zero values.updates_available
returns false
, then there are no packages to fetch.download_only
is specified as true
, the packages will also be installed.RecoveryUpgradeByFile (path: s) -> (result: y)
path
.RecoveryUpgradeByRelease (version: s, arch: s, flags: q) -> (result: y)
FetchUpdates
task will execute beforehand.how
defines how the recovery partition should be upgraded.
file
and release
.version
defines the suite to fetch from (ie: 20.04
)arch
defines which variant of that version to fetch (ie: nvidia
)flags
sets additional configuration parameters for the taskRefreshOS () -> (result: y)
ReleaseCheck () -> (current: s, next: s, build: n)
current
release, determines the next
release, and states whether
an update is available
or not.ReleaseUpgrade (how: q, from: s, to: s)
from
defines which suite to upgrade from.to
defines the suite to upgrade to.how
.
1
will use systemd to perform an offline upgrade.2
will use the recovery partition to perform an offline upgrade.ReleaseRepair ()
/etc/fstab
file will be corrected if certain mounts are missing or are mounting by the wrong IDStatus () -> (status: q, sub_status: q)
status
has a sub_status
, it will be set to a non-zero value.0
: Inactive,1
: Fetching Packages,2
: Recovery Upgrade,3
: Release Upgrade,4
: Package UpgradeUpgradePackages ()
PackageFetchResult (status: q)
FetchUpdates
task completed0
indicate success, whereas 1
indicates failurePackageFetched (package: s, completed: u, total: u)
FetchUpdates
task has fetched a package.package
refers to the name of the package that was fetched.completed
and total
can be used to track the progress of the task.PackageFetching (package: s)
FetchUpdates
task has begun fetching a new package.package
refers to the name of the package that was fetchedPackageUpgrade (event: a{ss})
RecoveryDownloadProgress (progress: t, total: t)
RecoveryUpgradeEvent (event: q)
RecoveryUpgradeResult (result: y)
ReleaseUpgradeEvent (event: q)
ReleaseUpgradeResult (result: y)
Fetching
(1
): fetching recovery filesSyncing
(2
): syncing recovery files with recovery partitionVerifying
(3
): verifying checksums of fetched filesComplete
(4
): recovery partition upgrade completedFailed
(5
): recovery partition upgrade failedUpdatingPackageLists
(1
): updating package lists for the current releaseFetchingPackages
(2
): fetching updated packages for the current releaseUpgradingPackages
(3
): upgrading packages for the current releaseInstallingPackages
(4
): ensuring that system-critical packages are isntalledUpdatingSourceLists
(5
): updating the source lists to the new releaseFetchingPackagesForNewRelease
(6
): fetching packages for the new releaseAttemptingLiveUpgrade
(7
): attempting live upgrade to the new releaseAttemptingSystemdUnit
(8
): creating a systemd unit for installing the new releaseAttemptingRecovery
(9
): setting up the recovery partition to install the new releaseSuccess
(10
): new release is ready to installSuccessLive
(11
): new release was successfully installedFailure
(12
): an error occurred while setting up the upgradeLicensed under the GNU General Public License, Version 3.0, (LICENSE or https://www.gnu.org/licenses/gpl-3.0.en.html)
Any contribution intentionally submitted for inclusion in the work by you, shall be licensed under the GNU GPLv3.