Skip to content

fix: use generic flatpak command in .desktop (fixes #127)#182

Open
gabrielalmir wants to merge 1 commit into
masterfrom
fix-flatpak-path-127
Open

fix: use generic flatpak command in .desktop (fixes #127)#182
gabrielalmir wants to merge 1 commit into
masterfrom
fix-flatpak-path-127

Conversation

@gabrielalmir

@gabrielalmir gabrielalmir commented Apr 4, 2026

Copy link
Copy Markdown
Collaborator

Addresses #127.

This PR replaces the absolute path /usr/bin/flatpak with a generic flatpak command in the .desktop file, improving compatibility across various Linux distributions (like NixOS).

@gabrielalmir gabrielalmir self-assigned this Apr 4, 2026
@gabrielalmir gabrielalmir added the bug Something isn't working label Apr 4, 2026
@gabrielalmir

gabrielalmir commented Apr 4, 2026

Copy link
Copy Markdown
Collaborator Author

I would like to open a discussion regarding the implications of switching from an absolute path (/usr/bin/flatpak) to a generic "f latpak" command in the ".desktop" file.

While this change fixes compatibility for distributions like NixOS, there are potential edge cases to consider:

  1. PATH availability in GUI sessions: Desktop environments sometimes have a more restricted PATH than interactive shells. Could this cause the launcher to fail on systems where f latpak is installed in a non-standard location not included in the session's environment?
  2. Security & Binary Hijacking: Relying on PATH search order theoretically allows for binary spoofing if a different "f latpak" executable exists earlier in the search path.
  3. Cross-Distro Consistency: Is there a consensus or standard preference among major desktop environments (GNOME, KDE, etc.) regarding absolute vs. relative paths in Exec lines for Flatpak applications?

I'd love to hear the community's thoughts on this.

@gabrielalmir gabrielalmir marked this pull request as ready for review April 4, 2026 15:35
@gabrielalmir gabrielalmir requested a review from Diolinux April 4, 2026 15:36
@emsspree

Copy link
Copy Markdown
Contributor

Cross-Distro Consistency: This is handled differently by every distro. Some prefer comfort (without path), and some prefer security (with path).

As PhotoGIMP should work out of the box for everyone, it should use flatpak without path.

@gabrielalmir gabrielalmir requested review from Diolinux and removed request for Diolinux July 1, 2026 17:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants