Ubuntu Budgie - Automated PPA maintenance tool

Hello Ubuntu Budgie community.

During our last Internal Meeting with Ubuntu Budgie team, I proposed an idea that met some good feedback, so here I am.
The basic concept is to make release upgrades smoother and easier, especially for less tech savvy users.

Premise

I strongly believe that Ubuntu’s PPAs are both a blessing, and a curse. PPAs give developers a very easy way to create and share code, without having to deal with the hard and slow process of submitting packages to Debian and Ubuntu official repositories. I understand that it would be better for many cases. However that is not the reality of how things are working, and PPAs are still very popular.
Snaps promise to partially solve the “too many PPAs” issue, but Snaps for desktop apps are still met with a bit of resistance, as they don’t offer better performance, often miss out on theming, and other paper cuts.

My experience with PPAs

I use PPAs, a lot of them. I don’t really have a problem as I have been using Linux since the old times of Slackware. Having said that, I often jump to interim releases, development branches, and managing all that PPA overhead is often a bit of a chore.

New Ubuntu user experience with PPAs

Over the years, I have been helping quite a few new users with Ubuntu or Ubuntu Flavours. I help them setup their machines and off they go with the latest LTS. However, many times users also want to experience latest and greatest. And as soon as they do a release upgrade, all their PPAs get disabled automatically. And after release upgrade is completed, all 3rd party PPAs are left disabled. Users are completely unaware of this and don’t know how to check and update their repos. Some times I have seen them just manually re-add new versions of the PPAs. Long story short, after 3 release upgrade their list of PPAs looks like an old junkyard.
They no longer get updated software they think they are getting, and so on.

How is it that I tackle the issue? Quick run down of the logic

My idea came from a quick reference manual I wrote for myself a long time ago. So, what is it that I do to keep my PPAs healthy and in check?

  1. Write down a list and then Purge PPAs that hold special kernels or mesa stack before release upgrade
  2. Do release upgrade
  3. After release upgrade, go check each disabled PPA. Go to launchpad and see if that PPA is available for my new release.
    3a. If disabled PPA is available for my new release, change codename in PPA entry
    3b. If disabled PPA is not available for my new release, List item in my calendar, check after a week.
  4. Refresh repositories, run updates.
  5. Reboot system and check if everything works fine.
  6. Get all purged PPAs from my list, go to launchpad and see if that PPA is available for my new release.
    6a. If purged PPA is available for my new release, change codename in PPA entry
    6b. If purged PPA is not available for my new release, List item in my calendar, check after a week.

Automation

This is a long and tedious procedure. And as I previously mentioned, not everyone knows how to properly manage it. So why don’t we automate? I believe we can start with the logic I wrote above, and start with a bash script to handle. Obviously if someone steps up and wants to write this with another language, I have no arguments.

Final touches

I strongly believe education is a powerful tool. If we can show the users what needs to be done, and how the tool works, we can empower them to choose what happens for each item. And in my opinion, this will be a win-win scenario. Ubuntu Budgie teaching users a few tricks, make them more aware of how their system works. And in the long run we might have a lot of advanced users and who knows, maybe they would be even willing to help support new users, or make some contributions to the project.

GUI

Once we have a script that can handle the tasks, we can then regroup and see how to make a simple gui that shows what is happening, lets user pick action for each PPA. Few examples:

  1. We found disabled PPA1, which has a release file that matches your current release, would you like to update and enable it?
  2. We found disabled PPA2, but it appears there is not yet a release file that matches your current release. Would you like to leave it disabled until next check or remove it from your list of PPAs?

Future improvements

Once we have a basic product that works well and helps users, we can even consider further improvements. A few ideas:

  1. Check which Package(s) are installed from each PPA, and search ubuntu official repos, partner, universe, multiverse, if those packages are not included in official repositories. Ask user if he/she wants to remove PPA and use official repos instead.
  2. Check for abandoned PPAs that are no longer updated and inform the user if he/she wants to check link to launchpad PPA, disable it, leave it enabled, or remove it.
2 Likes