sonnyp / Junction

Application/browser chooser
https://flathub.org/apps/re.sonny.Junction
GNU General Public License v3.0
467 stars 29 forks source link

Host Chromium won't show in Junction flatpak #3

Closed sonnyp closed 2 years ago

sonnyp commented 2 years ago

When running Junction as a flatpak, Chromium is listed if it's installed as a flatpak but not if it's installed on the host.

The problem doesn't appear to be related to Exec or TryExec.

daniwasonline commented 2 years ago

This is also reproducible with Firefox, in which it will only be listed if it's installed as a Flatpak. If installed on the host, it won't appear in Junction's selection menu.

System:

Browsers:

sonnyp commented 2 years ago

Only Firefox won't show up or both Firefox and Firefox Developer Edition ?

Could you share the .desktop files?

/usr/share/applications/firefox.desktop and /usr/share/applications/firefox-developer-edition.desktop

sonnyp commented 2 years ago

Do you have Firefox / Firefox Developer Edition installed as flatpaks as well?

Junction de-duplicates apps if they have the same id - that would be the cause of your issue.

sonnyp commented 2 years ago

Nevermind - I found the problem with Firefox / Firefox Develper Edition on Arch. Exec points to /usr/lib/firefox/firefox which isn't available in the sandbox.

$ cat /usr/share/applications/firefox.desktop
[Desktop Entry]
Version=1.0
Name=Firefox
...
Exec=/usr/lib/firefox/firefox %u
...
$ cat /usr/bin/firefox
#!/bin/sh
exec /usr/lib/firefox/firefox "$@"
sonnyp commented 2 years ago

Fixed in Junction 1.1.0 - should be available on flathub shortly.