Page 1 of 1

Making PM default browser on Debian

Posted: 2018-10-09, 19:51
by loxodont
There's a question on the german language board about making (and keeping) Pale Moon the default browser on Debian (stable)
viewtopic.php?f=7&t=20624

berni says he installed Pale Moon deb package and set it to default browser when asked, but it seems to switch back to Firefox somehow ...
I never used Debian and don't know the mentioned terminal commands, so can anyone here help with this?
I'll translate it then to the original post.
thx

Re: Making PM default browser on Debian

Posted: 2018-10-11, 20:15
by stevenpusser
loxodont wrote:There's a question on the german language board about making (and keeping) Pale Moon the default browser on Debian (stable)
viewtopic.php?f=7&t=20624

berni says he installed Pale Moon deb package and set it to default browser when asked, but it seems to switch back to Firefox somehow ...
I never used Debian and don't know the mentioned terminal commands, so can anyone here help with this?
I'll translate it then to the original post.
thx
Possibly he may have to set it as the default browser in the desktop environment's settings, or as the default "x-www-browser" in the Debian alternatives system (galternatives is a nice GUI for this; KDE users can use kalternatives)

Re: Making PM default browser on Debian

Posted: 2018-10-12, 09:35
by loxodont
thx steve, I'll tell him.

Re: Making PM default browser on Debian

Posted: 2019-01-04, 11:58
by berni
I'm answering here directly, 'caus I think it's easier without having loxodont as a proxy (thanks for that anyway).
Possibly he may have to set it as the default browser in the desktop environment's settings, or as the default "x-www-browser" in the Debian alternatives system (galternatives is a nice GUI for this; KDE users can use kalternatives)
This is not, what I'm looking for. I don't want to change the system wide default browser (which influences other users), but the default browser on my local account.

Meanwhile I found out, that PM creates a file called ~/.config/mimeapps.list when I click on "Make Pale Moon the default browser" in Settings->Advanced.

With the command "xdg-settings get default-web-browser" I can query the default browser. Here some protocol:

$> xdg-settings get default-web-browser
firefox-esr.desktop
[Now I clicked on "Make Pale Moon the default browser"]
$> xdg-settings get default-web-browser
/usr/bin/xdg-mime: 912: local: Moon-XYVHQZ.desktop: bad variable name
firefox-esr.desktop


Investigating on that error message, I found out that the space in "Pale Moon" in the file ~/.config/mimeapps.list causes the trouble. The shell script /usr/bin/xdg-mime seems to consider that space as a separator and not part of the entry. Now I replaced that space by a minus and "xdg-settings get default-web-browser" works:

$> xdg-settings get default-web-browser
userapp-Pale-Moon-XYVHQZ.desktop


But still firefox is lounched, probably, because the minus-sign is wrong and PM cannot be found.

Re: Making PM default browser on Debian

Posted: 2019-01-04, 12:26
by vannilla
Isn't that entry the name of a file?
You'd also have to change the file's name to match the changes you applied.
(I'm not 100% sure it's the cause since my system does it in a different way, but it's worth taking a look.)

Re: Making PM default browser on Debian

Posted: 2019-01-04, 12:38
by Moonraker
Have you tried uninstalling firefox and then see what happens.?.perhaps not much help but maybe a reinstall would help.sorry its not much help.

Re: Making PM default browser on Debian

Posted: 2019-01-04, 13:05
by murga
File on path /etc/alternatives/x-www-browser link to /usr/bin/firefox or palemoon

Re: Making PM default browser on Debian

Posted: 2019-01-04, 13:28
by berni
vannilla wrote:Isn't that entry the name of a file?
You'd also have to change the file's name to match the changes you applied.
(I'm not 100% sure it's the cause since my system does it in a different way, but it's worth taking a look.)
I found this file at ~/.local/share/applications/ renamed it and it works, when I use xdg-open but unfortunatley not, when clicking a link in my email program... It seems to use a different approch to find out about the default browser...

As a side note: I think, pale moon should rename that file and the entries in mimeapps.list too. In my eyes the space there is a bug.

Now, I will continue to investigate, how my e-mail program starts the default browser...

PS: The e-mail program has some preferences which I changed from "firefox" to "xdg-open". Now it works.