How to add/remove PPA repositories in Debian?

PPA repositories are one of the things that Ubuntu likes the most. It is a personal repository that allows independent developers a platform to distribute their packages for Ubuntu. However, many of these packages are compatible with Debian and so it is necessary to know how to add them to Debian. This is exactly what you will learn in this post, how to add and remove PPA repositories in Debian.

Repositories and PPA

First of all, it is necessary to know what is a repository in Linuxhttps://www.imaginelinux.com/introducing-deepin-linux/.

In Linux, packages and applications are usually hosted in a repository. These repositories may be official, that is, included with the distribution, or they may be unofficial or unrelated to the distribution.

In short, a repository is a store or space where packages are hosted. These repositories have specific characteristics that make them compatible with the Linux distribution.

These repositories are usually managed by each distribution. That is, each distribution is responsible for the packages it distributes to each of its users. But what happens if I am a developer and I want to distribute my program?

The truth is that it is not so easy that you can include it in an official repository, so the best option is to have one of your own or package it and distribute it through a website or other tool.

So, a PPA (Personal Package Archive) is a special repository hosted on Launchpad that is perfectly compatible with Ubuntu. So if you are an independent developer, you can package your application and distribute it using a PPA. The big advantage for the user is that every time you update the application and the user has your repository added, then he can update it without any problems.

PPAs are mainly used in Ubuntu, but it is also possible to add them in Debian.

How to add/remove PPA repositories in Debian

Debian is a quite popular but somewhat closed operating system in package management. While it is true that there are many packages included in Debian, it is also true that many popular applications are not in its repositories.

So, there are times when it is necessary to add a PPA.

For this, we can do it via the terminal, which is a very fast method.

First, install the necessary package to add PPAs in Debian:

apt install software-properties-common

Open a terminal from the main menu and to add a PPA, follow this syntax as the root user.

add-apt-repository ppa:ppa_name

For example:

add-apt-repository ppa:jonathonf/nimlang

After that, you can refresh APT.

apt update

And finally install any package from this repository:

apt install [package]

And it’s that simple.

Removing a PPA repository on Debian

To remove a repository, we can use the same command but add the -remove

The usage syntax is as follows:

add-apt-repository -remove ppa:ppa_name

Or in this case:

add-apt-repository ppa:jonathonf/nimlang

And with this, the PPA is eliminated.

Method 2: Remove the PPA manually

Another way to remove a PPA is to do it manually by removing its entry in the folder that APT dedicates to software sources.

First, show all the repository files that are in Debian

ls /etc/apt/sources.list.d/

And then, just delete it with the rm command

rm /etc/apt/sources.list.d/[ppa-name]

For example:

sudo rm /etc/apt/sources.list.d/jonathonf-ubuntu-nimlang.list

And that’s how simple it is to remove a PPA in Debian.

Adding/Removing PPA on Debian using the GUI

Debian is used both on servers and on the desktop. That’s why you may prefer to use the graphical interface.

From the main menu open the program called Software and Updates and go to the tab Other Software

Add / Remove PPA repositories in Debian
Add / Remove PPA repositories in Debian

From this interface, you only have to press one of the buttons according to the operation you need. To add a PPA just click on Add and to remove a PPA just select one and click on Remove.

Conclusion

Adding PPA in Debian is a simple task but it is convenient to know that we add PPA to avoid instabilities. Now that you know you can add some.

Let us know what you think, do you use Debian? do you like it? do you use PPA? leave us a comment and share this post.

Scroll to Top