ppa-purge
disable a Launchpad PPA and revert its packages to official versions
TLDR
SYNOPSIS
ppa-purge [-h] [-d distribution] [-s host] [-p ppaname] [-o ppaowner] [-y] [-i] [ppa: ppaowner[/ppaname]]
DESCRIPTION
ppa-purge is a bash script that disables a Launchpad Personal Package Archive (PPA) and downgrades packages that came from that PPA back to the versions in the official Ubuntu archive. Packages that exist only in the PPA are uninstalled. Removing a PPA with add-apt-repository --remove leaves the installed versions in place; ppa-purge is the rollback for that case.The PPA may be given as `ppa:owner/name`, as a bare `owner/name`, or as --o / -p flags. When the name is omitted it defaults to ppa, matching Launchpad's default archive name.The script must run as root because it calls the package manager. It comments out the matching source list entries, generates a revert list, and installs the archive versions.
PARAMETERS
-p ppaname
PPA name to disable (default: ppa)-o ppaowner
Launchpad PPA owner. If omitted, the owner is taken from the `ppa:owner[/name]` argument-s host
Repository server (default: ppa.launchpad.net)-d distribution
Override the detected Ubuntu distribution (for example noble or jammy)-y
Pass -y --force-yes to apt-get, or -y to aptitude-i
Prefer aptitude over apt-get (the default prefers apt-get)-h
Display usage help and exit
INSTALL
CAVEATS
ppa-purge is Ubuntu-specific (package in the universe pocket). It does not delete the source list file; it disables the PPA. If a run fails (for example because another package manager is holding the lock), uncomment the PPA, run apt-get update, and try again. Packages with no counterpart in the official archive may remain installed and have to be removed by hand. Using -y skips the review of the proposed downgrade list.
HISTORY
ppa-purge was written for Ubuntu to undo PPA upgrades. The man page is dated 2010 (Lorenzo De Liso). Ubuntu later switched the default Launchpad host in packaging notes to ppa.launchpadcontent.net; the script's -s default remains ppa.launchpad.net.
SEE ALSO
add-apt-repository(1), apt(8), apt-get(8), apt-cache(8)
