Closed POMATu closed 1 year ago
Well, first thing is that Firefox stores its preferences in text file called pref.js, usually in /home/username/.mozilla/firefox/something.default There is systemwide prefs located in /usr/lib/firefox/defaults/pref/ yous hould try to play with those.
Well, first thing is that Firefox stores its preferences in text file called pref.js, usually in /home/username/.mozilla/firefox/something.default There is systemwide prefs located in /usr/lib/firefox/defaults/pref/ yous hould try to play with those.
As you can tell by reading the text at the top of that file, it's not recommended to edit it directly:
// Mozilla User Preferences
// DO NOT EDIT THIS FILE.
However, you can have firefox modify these settings by putting them in a file named user.js
. Here are step-by-step instructions for anybody who would like to do this:
First, in Firefox, open a new tab and type in the address about:profiles and hit enter to go there. This page will list all of your Firefox profiles. One of them will be marked as the current profile in use:
This is the profile in use and it cannot be deleted.
This is the profile you want to edit, obviously. Just below this line, you will see the directory where the profile is stored, in a table, labelled Root Directory
, and at the end of that line, there will be a button titled 'Open Directory'. Click it to open your profile directory in your file browser. You will see your profile directory with all of your profiles there, and the one you want will be highlighted, so just press enter or double-click on it to open the profile folder.
Once you're in there, create a file named user.js
. If it already exists, you can edit the existing file.
Add in the lines with the required preferences. Mine looks like this:
// ElFarto NVDEC
user_pref("media.ffmpeg.vaapi.enabled", true);
user_pref("media.rdd-ffmpeg.enabled", true);
user_pref("gfx.x11-egl.force-enabled", true);
user_pref("widget.dmabuf.force-enabled", true);
This covers all of the options specified in the readme. If you like, you can add other settings in there too, like the one you mentioned in the OP:
user_pref("layers.gpu-process.enabled", true);
Or the optional one from the readme
user_pref("media.av1.enabled", false);
When you start firefox, all of the settings in user.js
will be applied (ie, if it's running right now, you should exit it and start it up again to apply these changes).
If you create a new profile, or if yo use multiple profiles, you can just copy this file into that profile directory and you're done. You will find the profile directory in the about:profiles page mentioned above.
Hope that helps!
Originally posted by @Vednier in https://github.com/elFarto/nvidia-vaapi-driver/issues/182#issuecomment-1483926523
Thats too much of them already. Utterly not practical to enable em all everywhere manually and also in each new profile you create and also not forget to do all that each time you create new profile.
Anybody knows how to have them enabled by default per installation of firefox? So new profiles are already having those flags set init. Another idea is to make some shell script that patches some settings.sqlite. I could possibly write that because i need it myself so badly but I still dont know how to hook it so it executes on new creation of profiles and before its loaded.
So im wondering maybe there is more clean way of doing that per whole instalaltion rather than shell script