Publishing CLI app on Flathub + small question on appdata.xml

Hi, I’m trying to publish my first Flatpak app on Flathub, which in this case is a simple CLI tool that creates a vector graphic from data in a CSV file.

My code is saved here. I have managed to build the Flatpak itself, but I’m not completely sure about how to integrate the metadata (Appstream).

In the YML file I have written:

  - install -Dm644 net.launchpad.Gnuclad.appdata.xml /app/share/metainfo/net.launchpad.Gnuclad.appdata.xml

Is that the right way to do it?

Then in the appdata.xml it self, I’m not sure what to put in the binary tag. Should I use the normal CLI command (gnuclad) or the Flatpak name (net.launchpad.Gnuclad) or the command to invoke the built Flatpak (flatpak run net.launchpad.Gnuclad)? Or do I not need the binary tag?

Final question: Is there any point in creating a .desktop file for the Flatpak? As said, it is a pure CLI app and one of the type that terminates after it does the job, not one that stays on the screen until the user quits it (like htop or nano). So I feel like a .desktop file may be pointless, but also something that’s expected to publish on Flathub?

1 Like

Desktop files are not needed for cli apps afaik.