The mess that is 'default browser'
Tony Arnold
a.c.arnold at gmail.com
Sat Nov 6 18:01:04 UTC 2021
Hi Chris,
On Sat, 6 Nov 2021 at 16:41, Chris Green <cl at isbd.net> wrote:
> I have recently changed from Firefox to Opera on one of my systems.
> So I told Opera to set itself as the default browser, hmmmm!
>
> On investigating I found that the whole 'default browser' set up is a
> disaster, after setting Opera as default I see the following on the
> 21.10 system where I changed from Firefox to Opera:-
>
> /usr/bin/gnome-www-browser points at
> /etc/alternatives/gnome-www-browser
> which points at /usr/bin/opera.
>
> /usr/bin/x-www-browser points at /etc/alternatives/x-www-browser
> which points at /usr/bin/firefox.
>
> /usr/bin/sensible-browser is a script which checks the BROWSER
> environment variable if that's not set will try gnome-www-browser
> and then x-www-browser.
>
>
Have you tried setting the default browser using 'Default Applications'
under settings? That might set all the relevant links.
> On another (21.04) system where I have been using Epiphany/Web in
> parallel with Firefox both gnome-www-browser and x-www-browser are set
> to epiphany-browser in /etc/alternatives but the BROWSER environment
> variable is still set to Firefox.
>
>
> So I am at a bit of a loss as to what program name to use to call a
> web browser in scripts! I guess the best approach might be to use
> sensible-browser and set the BROWSER environment variable. It does
> make a bit of a nonsense of 'default browser' though!
>
If in you script you are opening a specific page, then you could use
xdg-open and that should start the default brwoser.
Regards,
Tony.
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20211106/acbceb6b/attachment.html>
More information about the ubuntu-users
mailing list