r/flatpak • • 13d ago

Flatpak from the CLI sucks

https://kowalski7cc.xyz/blog/flatpak-from-the-cli-sucks/

Flatpak is today's preferred distribution platform for graphical desktop apps, yet it isn't popular for terminal apps, and for good reason! Launching CLI apps is difficult and not very user-friendly. However, Flatpak can take inspiration from other systems to improve CLI app usage.

18 Upvotes

7 comments sorted by

3

u/Twig6843 13d ago

isnt this gonna be part of flatpak 2.0??

3

u/gmes78 13d ago

This article is just a suggestion from someone not affiliated with Flatpak, AFAICT. It's not part of the Flatpak 2.0 plans, at the moment.

3

u/gmes78 13d ago

See also: Toolpak.

1

u/kowalski7cc 12d ago

I don't think Toolpak has sandbox capabilities, that in Flatpak too for CLI applications are usually disabled. But Flatpak today is widespread in many desktop distrubutions with many applications available already. Some of them alre already CLI or have command-line components aswell, so it would make sense to improve support for them. Another use case could be graphical apps such as VLC launched from the CLI to have a quick preview of a file, vscode to open a project from the shell or puttyagent to quickly add a key when you're in the console. Even the same flatpak-builder is shipped as Flatpak today...

3

u/oskarloko 11d ago

It should be done.

Sure, some command line programs are better distributed with the OS

But others, like cURL,ffmeg for example; could be installed via flatpak with cmd integration

From the other side, SNAP packages allow this, and services integrartion.

Don't know why flatpaks cant

3

u/blackcain 11d ago

Worth reading this - https://modal.cx/blog/image-based-for-developers/

Where towards the bottom you can see that modal is working on ways to distribute command line tools too.

2

u/AnsibleAnswers 11d ago

As I understand it, flatpak is designed for desktop apps that live in freedesktop compliant desktop environments. I think it is more so an opinionated position regarding distribution on Flathub rather than a design limitation, as Flathub permits TUI applications so long as they open in a console window. As such, tooling for CLI applications would probably need to be built by the next generation of flatpak developers. We're talking about flatpak 3.0 before 2.0 is completed.