Configuring Pale Moon default preferences

Users and developers helping users with generic and technical Pale Moon issues on all operating systems.

Moderator: trava90

Forum rules
This board is for technical/general usage questions and troubleshooting for the Pale Moon browser only.
Technical issues and questions not related to the Pale Moon browser should be posted in other boards!
Please keep off-topic and general discussion out of this board, thank you!
arturo83

Configuring Pale Moon default preferences

Unread post by arturo83 » 2019-12-05, 14:31

Three years ago, when Pale Moon was still at version 26.1.1, I found a way to set default preferences for every new profile created.
In that time my Pale Moon installation was in the /opt folder.
So I created the directory /opt/palemoon/browser/defaults/profile/
There I put my configuration files: prefs.js, bookmarks.html and localstore.rdf.
Now I tried to do the same in Pale Moon 28.7.2, but it didn't work.
Assuming that I have to change the content of those files, where have I to create them to globally configure Pale Moon, without the need to customize every new profile?

User avatar
therube
Board Warrior
Board Warrior
Posts: 1651
Joined: 2018-06-08, 17:02

Re: Configuring Pale Moon default preferences

Unread post by therube » 2019-12-05, 20:57

Looks to be working on my end.

- copied existing prefs.js into /defaults/profile/
- deleted existing profile
- started PM

PM opened using the prefs.js found in /defaults/profile/.

Bookmarks.html is no longer used, instead, places.sqlite.
(Bookmarks.html can be exported to, or imported from, but it is no longer the default storage location for bookmarks.)

(I didn't try localstore.rdf.)


---


(From the Mozilla end... so suppose it will also apply to PM.)

Deploying Firefox in an enterprise environment (before Firefox 60 ESR)

Now that uses, autoconfig.js & mozilla.cfg.

arturo83

Re: Configuring Pale Moon default preferences

Unread post by arturo83 » 2019-12-06, 15:07

What version of Pale Moon are you using?
I'm using version 28.7.2. I tried again but it doesn't work at all.
I tried to put the files in /palemoon/browser/defaults/profile/ and also in /palemoon/defaults/profile/ but it doesn't work.
I found something, searching the web, so I tried another method:
I put the prefs.js file in /palemoon/browser/defaults/preferences/ and Pale Moon used some af the preferences set in the file, but not all of them.
For example I could suppress the first run and disabled the default browser check, but I couldn't set the new home-page and the default search-engine.
I used the following code:

Code: Select all

# Mozilla User Preferences

pref("browser.startup.homepage_override.mstone", "ignore");
pref("browser.startup.homepage", "https://www.startpage.com/");
pref("browser.search.defaultenginename", "Startpage.com - English");
pref("browser.shell.checkDefaultBrowser", false);
More over I need new profiles to use my version of the xulstore.json file, but I couldn't find a way to do this.
In older versions of Pale Moon (eg. 26.1.1) it was possible to do so, but now how can it be done?

New Tobin Paradigm

Re: Configuring Pale Moon default preferences

Unread post by New Tobin Paradigm » 2019-12-06, 15:57

This is TOTALLY not the right way to go about this. Search the forum for mozilla.cfg. Moonchild has elaborated to some extent about it at SOME point.

User avatar
adesh
Board Warrior
Board Warrior
Posts: 1277
Joined: 2017-06-06, 07:38

Re: Configuring Pale Moon default preferences

Unread post by adesh » 2019-12-06, 16:14

Solution is here: Issue #905 (UXP)

arturo83

Re: Configuring Pale Moon default preferences

Unread post by arturo83 » 2019-12-06, 19:48

Thanks for your replies.
Finally I used the guide from Mozilla about Customizing Firefox Using AutoConfig.
So I created the autoconfig.js file into the /palemoon/defaults/pref/ directory using the following syntax:

Code: Select all

pref("general.config.filename", "palemoon.cfg");
pref("general.config.obscure_value", 0);
Then I create the palemoon.cfg file into the /palemoon/ directory using the following syntax:

Code: Select all

// Default Preferences
pref("browser.startup.homepage_override.mstone", "ignore");
pref("browser.startup.homepage", "https://www.startpage.com/");
pref("browser.search.defaultenginename", "Startpage.com - English");
pref("browser.shell.checkDefaultBrowser", false);
Now all the preferences work, except the one regarding the default search-engine.
I also tried to add the following line, but it still doesn't work:

Code: Select all

pref("browser.search.selectedEngine", "Startpage.com - English");
When I check the prefs.js file into the profile folder, I can see all the preferences I set in the palemoon.cfg file, except the one regarding the default search-engine.
Is there anything I can do to solve the problem?

User avatar
adesh
Board Warrior
Board Warrior
Posts: 1277
Joined: 2017-06-06, 07:38

Re: Configuring Pale Moon default preferences

Unread post by adesh » 2019-12-06, 20:07

Search engine preference name is browser.search.defaultenginename.

arturo83

Re: Configuring Pale Moon default preferences

Unread post by arturo83 » 2019-12-06, 20:28

adesh wrote:
2019-12-06, 20:07
Search engine preference name is browser.search.defaultenginename.
Yes, I already inserted that line, but it still doesn't work.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35600
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Configuring Pale Moon default preferences

Unread post by Moonchild » 2019-12-06, 20:43

Startpage is not a built-in search engine. If it doesn't know about it, then setting the pref will not work.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

arturo83

Re: Configuring Pale Moon default preferences

Unread post by arturo83 » 2019-12-06, 21:03

Yes, it's true, but I added the file startpagecom---english.xml in the /palemoon/browser/searchplugins/ directory, and I can correctly select the Startpage search-engine from the drop-down menu of Pale Moon.
I only wish to make it the default search-engine without the need to manually select it, so that every new created profile will have it by default.

User avatar
adesh
Board Warrior
Board Warrior
Posts: 1277
Joined: 2017-06-06, 07:38

Re: Configuring Pale Moon default preferences

Unread post by adesh » 2019-12-07, 12:28

Maybe you are setting wrong value for the pref. Change your search engine to Startpage or whatever you want then go to about:config to see the value you need to use in your defaults file.

New Tobin Paradigm

Re: Configuring Pale Moon default preferences

Unread post by New Tobin Paradigm » 2019-12-07, 15:36

You're already beyond support territory imo. Why are you altering program files and doing pref autoconfig?

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35600
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Configuring Pale Moon default preferences

Unread post by Moonchild » 2019-12-07, 16:09

New Tobin Paradigm wrote:
2019-12-07, 15:36
You're already beyond support territory imo.
Absolutely.

@arturo: I really do hope you're not publicly deploying this. Where is this used that you need this autoconfig setup?
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

arturo83

Re: Configuring Pale Moon default preferences

Unread post by arturo83 » 2019-12-08, 15:28

First of all, I thank you all for your support.
Then, I'm not deploying this at all; it's only for my personal use.
I simply wish to customize the ISO image of my system to use it in live mode.
Am I doing something wrong? If yes, please tell me...

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35600
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Configuring Pale Moon default preferences

Unread post by Moonchild » 2019-12-08, 18:28

arturo83 wrote:
2019-12-08, 15:28
Am I doing something wrong?
No, if it's for personal use then by all means, hack away :)
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

Locked