I love Flatpaks, the programs are nicely separated so they don’t interfere with each other. They also don’t have flaws like Snap’s low performance or Nix’s complexity.

But being limited to only graphical apps seems like a real drawback. If one wants to use Flatpaks as their primary package manager there have to be some awkward workarounds for cli programs.

E.g., the prime Flatpak experiene is supposed to be on immutable distros like Silverblue. But to install regular cli programs you are expected to spin up a distrobox (or toolbox) and install those programs there.

Having one arch distrobox where I get my cli programs from will not work, as the package entropy over time will get me the very dependency issues that Flatpak wants to solve.

So what is the solution here? Have multiple distroboxes and install packages in those in alternation and hope the boxes don’t break? Use Nix alongside Flatpak? Use Snaps?

  • @[email protected]
    link
    fedilink
    131 year ago

    flatpak run org.gimp.Gimp image.png vs. gimp image.png or even xdg-open image.png. “Mildly unwieldy” I suppose but a massive pain in the ass in practice. I can’t believe they thought that it was a good idea to require all that and provide no way to create a script in /usr/local/bin or even .local/bin.

    • davel [he/him]
      link
      fedilink
      English
      19
      edit-2
      1 year ago

      echo 'alias gimp="flatpak run org.gimp.Gimp"' >> ~/.bash_profile

      • @[email protected]
        link
        fedilink
        321 year ago

        Oh my God I never thought of that! /s

        What a pain in the ass to require me to maintain a set of aliases for everything I install. Great user experience.

      • @optissima
        link
        71 year ago

        And the other 125 flatpaks I have?

      • @[email protected]
        link
        fedilink
        111 year ago

        That’s a pain in the ass. Why not automate it with the install? They already create .desktop files FFS.

        • @AProfessional
          link
          English
          191 year ago

          It is actually. Add /var/lib/flatpak/exports/bin to PATH.

              • @AProfessional
                link
                English
                11 year ago

                They are only aliases too. People will be disappointed if they expect it to behave like the unsandboxed command.

          • @[email protected]
            link
            fedilink
            2
            edit-2
            1 year ago

            Really? That’s a thing? I don’t mind a one-time PATH modification and was excited to see this but… I don’t see that path on my system. Maybe it’s optional and none of my applications are using it?

            I also don’t see any mention of that in the flatpak.org setup steps. And almost nobody replying here even knows about it. And all of the examples of running a flatpak from the CLI on flatpak.org and flathub.org use the flatpak run org.gimp.Gimp version.

            So it seems like it’s a feature, but it’s poorly documented, poorly advertised, and not used… :-(

            Edit: So I did find that directory on another system of mine. No idea why it’s there on one and not the other. Maybe a version thing. And gimp is symlinked as “org.gimp.Gimp”. What a failure… 🤦

    • @[email protected]
      link
      fedilink
      English
      31 year ago

      Flatpak should export mimetypes so xdg-open should work if there isn’t another handler registered