Default browser

In short, I currently have an app which I need to log into, presuming it’s possible. No, I actually need it, or I can’t go by public transportation, due to the current situation.
It requires a browser to login, and it default to the buildin browser. This however does nort work for this purpose, for whatever reason, so I need, at least for the moment, to change the default browser to another.

After 5+ years, naturally this is possible, but I can’t figure it out.
Please enlighten me.

I only tested this with native browsers and flatpak, not android. So for e. g. firefox you need to try it out.

Look for the .desktop file of your preferred browser in /usr/share/applications and copy it to ~/.local/share/applications/open-url.desktop. Look into this new file for the Exec tag. Make sure that this exec ends with an %U otherwise the browser will not open the url.

To let the original browser the standard browser again, remove open-url.desktop again. You may have two icons for your new default browser now. Ah, if you have some well-known browser installed via flatpak: This desktop file is also in ~/.local/share/applications`

I explicitly write ~/ instead of /home/nemo as your home directory because the user may change with SailfishOS 3.4.

3 Likes

I will have to try it once I get home. for now I’ve found alternative means. Still, I will most likely need this in the future, so thanks.

What is the best place to see upcoming changes like this to Sailfish? Is there something like a Github repository or similar site that shows the development progress of Sailfish?

The user change was mentioned here:

https://together.jolla.com/question/228946/sailfish-os-340-around-the-corner-user-name-change-nemo-defaultuser/

1 Like

Great news! What native browsers have you tested? How do I get a native browser running on SFOS?

Okay, so I finally got around to trying this out, but frankly, it doesn’t work, and the only editor I can find in the terminal is vi, which doesn’t help matters.
At any rate, there is one potential mistake I might have made, as it’s not exacly clear where that %U is suposed to be. I’ve tried putting it at the end of the exec “line”, with and without space in between. Without space it works, but doesn’t open the link, and with space it doesn’t work. I’ve even tried ’ %U’ as per some ancient forum post, and in between ‘line sections’, etc.

Please enlighten me as to how it’s supposed to be done, so I can know if it can work. If not, I probably have little choice but to back to android, because certain essential apps require another browser than the one we’ve got to log in, as it doesn’t work otherwise, because reasons.

I might also consider alternative browsers, but again, I need to know how to make it default.

Best regards.

Take a look at webcat or sailfisbbrowser desktop file

[nemo@Sailfish ~]$ cat /usr/share/applications/harbour-webcat.desktop[Desktop Entry]Type=ApplicationX-Nemo-Application-Type=silica-qt5Name=WebcatIcon=harbour-webcat
Exec=harbour-webcat %U
X-Desktop-File-Install-Version=0.23

[nemo@Sailfish ~]$ cat /usr/share/applications/sailfishbrowser.desktop
[Desktop Entry]Type=ApplicationName=Web BrowserX-MeeGo-Logical-Id=sailfish-browser-ap-nameX-MeeGo-Translation-Catalog=sailfish-browserIcon=icon-launcher-browser
Exec=invoker -s --type=browser -G /usr/bin/sailfish-browser %U
Comment=Sailfish UI application

This %U is to open the browser from CLI with the desired http address as parameter.

So when I’ve got something like:
Exec=apkd-launcher com.android-bla-bla.apk con.android.blabla.somethingorrather.Main
The %U goes where?
I’m sorry if I’m being dim, but are there any non android browser?
edit:
Just tried web pirate. That didn’t work either, for the purposes of login in, but otherwise the default browser thingymagic works fine.

The open source part is publicly available at https://git.sailfishs.org. You can easily follow the activity with this link:

The multi-user change has been visible for months already, with a lot of patches fixing stuff in package recipes, or removing here and there hard coded path in scripts…

1 Like