$ sudo add-apt-repository --remove --assume-yes ppa:ondrej/php
$ sudo apt update
$ sudo apt-get install ppa-purge
$ sudo ppa-purge ppa:ondrej/php
$ sudo apt update
$ sudo apt autoremove

Guide compatibility:

Operating System
Ubuntu 16.04 LTS (Xenial Xerus)
Ubuntu 16.10 (Yakkety Yak)
Ubuntu 17.04 (Zesty Zapus)
Ubuntu 17.10 (Artful Aardvark)
Ubuntu 18.04 LTS (Bionic Beaver)
Ubuntu 18.10 (Cosmic Cuttlefish)
Ubuntu 19.04 (Disco Dingo)
Discuss the article:

Comment anonymously. Login not required.

Share!