Proposal for Season of KDE - Flatpak Packaging

Brent Mackey bjdm.92 at gmail.com
Fri Jan 6 14:51:20 GMT 2023


Hi,

As per the flatpak matrix channel, I've drafted a proposal for the Season
of KDE project idea to package apps for Flathub.

Project type: Coding and Packaging
Brief explanation: We currently have Flatpaks recipes for a lot of KDE Apps
(https://invent.kde.org/packaging/flatpak-kde-applications) but only some
of them are available on Flathub (https://flathub.org/apps/search/org.kde).
You will work on submitting missing KDE Apps to Flathub while fixing the
issues that come up during the submission review. Once you've understood
the process better, you may start working on tooling to help maintain KDE
Apps as Flatpaks in both Flathub and KDE CI/CD infrastructure in GitLab.
Expected results: Submit a couple of KDE Apps to Flathub and develop fixes
for the issues found during review.
Knowledge Prerequisite: C++, Qt, CMake, Bash, Python (basic knowledge in at
least two of those is recommended)
Mentor: Timothée Ravier. Reach out to https://matrix.to/#/#flatpak:kde.org.

Proposal: KDE Apps packaging as Flatpak for Flathub
Based on my hacky python script, there are 61 apps hosted on kdeapps that
are not on Flathub (see below). These applications have existing flatpak
manifests on invent.k.o/packaging/flatpak-kde-applications, or their
respective repository, that would need to be ported over to comply with
Flathub's requirements (
https://github.com/flathub/flathub/wiki/App-Requirements).

My understanding of this process and how I would go about it is as follows:
    1. Clone individual repos and test builds locally to avoid polluting
merge requests and CI/CD jobs
    2. Determine which commit or release the flatpak should be pinned to
(use release service or speak with maintainers)
    3. Confirm stable release builds locally, preferably using the tools at
invent.kde.k.o/sysadmin/ci-utilities. Change module source to
https://download.kde.org/stable/release-service/$version/src/$app-$version.tar.xz
or appropriate
    4. Pin all other modules to appropriate archives or stable release
    5. Reconfirm build succeeds correctly using Flathub's SDK and Platform
modules (I don't think this is actually necessary)
    6. Ensure that each app's .desktop, icon, etc. files are renamed
correctly ie. org.kde.$APP.desktop
    7. Check conformance with Flathub AppData requirements using Flathub's
fork of appstream-util
    8. Check desktop-file-validate
    9. Set required permissions and file system access using portals. Use
ro where possible
    10. Confirm flatpak installs and runs correctly locally
    11. Clone flathub/flathub and create my own branch
    12. Create a PR against new-pr on github

If I was able to manage this, I would then go about automating the process
by adding another template using flatpak.yml as a starting point, adding
any additional steps required for for passing tests and ensuring builds to
ci-utilities.

Some other ideas I've had are:
    - making sure all runtimes are up to date for Flatpak builds across
both plaforms
    - A script to check that flathub builds are using the most recent
stable builds
    - Ensure reuse-lint is enabled on all repos being uploaded to Flathub
to ensure future compatibility
    - Work with flatpak packaging team to establish some best practices and
script testing of conformance

If I need to include more detail of any sort or need to clarify anything, I
am available on the matrix channel as bjdm or here.

Many thanks and I look forward to hearing from you
Brent

Apps on kdeapps and not flathub:
Arkade, AtCore Test Client, Atelier, Babe, Basket, Calindori, Gemini, Plan,
Cervisia, Discover, Dragon Player, Kate, KCharSelect, kdebugsettings, KDE
Connect, kdiff3-stable, kexi-stable, kexi, KFloppy, Khipu, Kirigami
Gallery, Kirogi, KItinerary Command Line Extractor, KItinerary Workbench,
kjournald, Klimbgrades, KMag, KMix, Kompare, Konqueror, Konsole,
konversation-konvi2x, Kopete, kosmindoormap, KRename, Krfb, krita-nightly,
krita-stable, KShisen, KSpaceDuel, KSystemLog, KTimer, Kube, KUserFeedback
Console, MyGNUHealth, Okular Mobile, Peruse, Phonebook, Plasma Camera,
PlasmaTube, portal-test-kde, Barcode Scanner, RKWard, RSI Break, Screen
Record, Skanlite, Skanpage, Spectacle, Step, Trojitá, Vakzination
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-soc/attachments/20230107/5e3724af/attachment.htm>


More information about the Kde-soc mailing list